updating test for strings with special characaters

This commit is contained in:
Michael Hunhoff
2021-03-23 16:02:47 -06:00
parent e51c79c241
commit 21359da766

View File

@@ -689,14 +689,12 @@ def test_string_values_special_characters():
name: test rule name: test rule
features: features:
- or: - or:
- string: hello\\r\\nworld - string: "hello\\r\\nworld"
- string: some\\path
""" """
) )
r = capa.rules.Rule.from_yaml(rule) r = capa.rules.Rule.from_yaml(rule)
children = list(r.statement.get_children()) children = list(r.statement.get_children())
assert (String("hello\r\nworld") in children) == True assert (String("hello\r\nworld") in children) == True
assert (String("some\\path") in children) == True
def test_regex_values_always_string(): def test_regex_values_always_string():