示例#1
0
def test_include_all_exclude_empty():
  var_name = get_var(rules[0], 'include-all-exclude-empty')
  var = Variable(var_name)
示例#2
0
def test_missing_required():
  with pytest.raises(KeyError):
    var_name = get_var(rules[0], 'missing-required')
    var = Variable(var_name)
示例#3
0
def test_omit_excludes():
  var_name = get_var(rules[0], 'omit-excludes')
  var = Variable(var_name)
示例#4
0
def test_empty_excludes():
  var_name = get_var(rules[0], 'empty-excludes')
  var = Variable(var_name)
示例#5
0
def test_empty_excludes_includes_with_spaces():
  var_name = get_var(rules[0], 'empty-excludes-includes-with-spaces')
  var = Variable(var_name)
示例#6
0
def test_minimal_var():
  var_name = get_var(rules[0], 'minimal-var')
  var = Variable(var_name)
示例#7
0
def test_constant(capsys):
  var_name = get_var(rules[0], 'constant')
  var = Variable(var_name)

  assert var.get_matches({}) == {'constant': 'constant-value'}