Example #1
0
def test_convert_field_values_string_value():
    EXPECTED = "Value"
    RESULT = parser.convert_field_value("String", "Value")
    assert EXPECTED == RESULT
Example #2
0
def test_convert_field_values_string_none():
    EXPECTED = None
    RESULT = parser.convert_field_value("String", ".")
    assert EXPECTED == RESULT
Example #3
0
def test_convert_field_values_character_value():
    EXPECTED = "X"
    RESULT = parser.convert_field_value("Character", "X")
    assert EXPECTED == RESULT
Example #4
0
def test_convert_field_values_character_none():
    EXPECTED = None
    RESULT = parser.convert_field_value("Character", ".")
    assert EXPECTED == RESULT
Example #5
0
def test_convert_field_values_flag():
    EXPECTED = True
    RESULT = parser.convert_field_value("Flag", True)
    assert EXPECTED == RESULT
Example #6
0
def test_convert_field_values_float_none():
    EXPECTED = None
    RESULT = parser.convert_field_value("Float", ".")
    assert EXPECTED == RESULT
Example #7
0
def test_convert_field_values_float_value():
    EXPECTED = 42.0
    RESULT = parser.convert_field_value("Float", "42")
    assert EXPECTED == RESULT
Example #8
0
def test_convert_field_values_integer_none():
    EXPECTED = None
    RESULT = parser.convert_field_value("Integer", ".")
    assert EXPECTED == RESULT
Example #9
0
def test_convert_field_values_integer_value():
    EXPECTED = 42
    RESULT = parser.convert_field_value("Integer", "42")
    assert EXPECTED == RESULT