def test_parse_context_repeated_key(): from lawyerup.core import parse_context from test.utils import Error vars = ["key1=val1", "key1=duplicate"] with pytest.raises(Error) as e: out = parse_context(vars) assert e.message == '"key1" specified multiple times!' assert out is None
def test_parse_context_repeated_key(): from lawyerup.core import parse_context from test.utils import Error vars = ['key1=val1', 'key1=duplicate'] with pytest.raises(Error) as e: out = parse_context(vars) assert e.message == '"key1" specified multiple times!' assert out is None
def test_parse_context(): from lawyerup.core import parse_context vars = ["key1=val1", "key2=val2"] expected = {"key1": "val1", "key2": "val2"} assert parse_context(vars) == expected
def test_parse_context(): from lawyerup.core import parse_context vars = ['key1=val1', 'key2=val2'] expected = {'key1': 'val1', 'key2': 'val2'} assert parse_context(vars) == expected