Skip to content

Commit

Permalink
feat: Add test for constructing type from string with multi underscor…
Browse files Browse the repository at this point in the history
…e prefix
  • Loading branch information
iron3oxide committed May 14, 2024
1 parent 71510ca commit e25ac64
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tests/test_typeid.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,16 @@ def test_construct_type_from_string_with_prefix_standalone() -> None:
assert isinstance(typeid.suffix, str)


def test_construct_type_from_string_with_multi_underscore_prefix() -> None:
string = "double_prefix_00041061050r3gg28a1c60t3gf"

typeid = TypeID.from_string(string)

assert isinstance(typeid, TypeID)
assert typeid.prefix == "double_prefix"
assert isinstance(typeid.suffix, str)


def test_construct_type_from_invalid_string() -> None:
string = "invalid_string_to_typeid"

Expand Down

0 comments on commit e25ac64

Please sign in to comment.