Skip to content

Commit

Permalink
Verify all specs in test data directory
Browse files Browse the repository at this point in the history
Ref. None
  • Loading branch information
senier committed Apr 25, 2024
1 parent eea0e8b commit a2be1ce
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions tests/integration/specs_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@

from rflx import expression as expr, pyrflx
from rflx.identifier import ID
from rflx.model.cache import AlwaysVerify
from rflx.pyrflx import PyRFLXError
from rflx.specification.parser import Parser
from tests.const import CAPTURED_DIR, GENERATED_DIR, SPEC_DIR
from tests.utils import assert_equal_code_specs

Expand Down Expand Up @@ -447,3 +449,10 @@ def test_tlv_generating_tlv_error(tlv_message_value: pyrflx.MessageValue) -> Non
tlv_message_value.set("Tag", "Msg_Error")
assert tlv_message_value.valid_message
assert tlv_message_value.bytestring == b"\x03"


@pytest.mark.parametrize("file", SPEC_DIR.glob("*.rflx"))
def test_specs(file: Path) -> None:
parser = Parser(AlwaysVerify())
parser.parse(file)
parser.create_model()

0 comments on commit a2be1ce

Please sign in to comment.