Пример #1
0
def test_simple_id_serialize():
    s = Simple(id="1", value="12")

    assert s.serialize() == {'id': "1", 'value': '12'}
Пример #2
0
def test_simple_serialize():
    s = Simple(value="12")

    assert s.serialize() == {"id": None, "value": "12"}