예제 #1
0
def test_multi_line(command, expected, code_dict):
    Code.multiline = True
    Code.code = code_dict
    eval_command(command)
    assert expected in Code.code.values()
예제 #2
0
def test_single_line(command, expected):
    Code.multiline = False
    Code.code = ""
    code = eval_command(command)
    assert code == expected
예제 #3
0
def test_data_types(command, expected):
    eval_command("assign 10 to variable x")
    assert expected == format_value(command)
예제 #4
0
def test_multi_line(command, expected, code_dict):
    Code.multiline = True
    Code.code = code_dict
    eval_command(command)
    assert expected in Code.code.values()
예제 #5
0
def test_single_line(command, expected):
    Code.multiline = False
    Code.code = ""
    code = eval_command(command)
    assert code == expected
예제 #6
0
def test_data_types(command, expected):
    eval_command("assign 10 to variable x")
    assert expected == format_value(command)