-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathtest_abweichung.py
More file actions
28 lines (25 loc) · 926 Bytes
/
test_abweichung.py
File metadata and controls
28 lines (25 loc) · 926 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
import pytest
from bo4e.com.abweichung import Abweichung
from bo4e.enum.abweichungsgrund import Abweichungsgrund
from tests.serialization_helper import assert_serialization_roundtrip
class Test_Abweichung:
@pytest.mark.parametrize(
"abweichung",
[
pytest.param(
Abweichung(
abweichungsgrund=Abweichungsgrund.UNBEKANNTE_MARKTLOKATION_MESSLOKATION,
abweichungsgrund_bemerkung="sonst",
zugehoerige_rechnung="458011",
abschlagsrechnung="4580112",
abweichungsgrund_code="14",
abweichungsgrund_codeliste="G_0081",
)
),
],
)
def test_serialization_roundtrip(self, abweichung: Abweichung) -> None:
"""
Test de-/serialisation of Abweichung.
"""
assert_serialization_roundtrip(abweichung)