Skip to content

Commit

Permalink
added test for warnings in register
Browse files Browse the repository at this point in the history
  • Loading branch information
Marco-Sulla committed Dec 31, 2023
1 parent e8c47e4 commit 62393ad
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion test/test_freeze.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from collections import OrderedDict
from array import array
from types import MappingProxyType
from frozendict import FreezeError
from frozendict import FreezeError, FreezeWarning


class A:
Expand Down Expand Up @@ -96,3 +96,8 @@ def test_deepfreeze_custom(a):
a,
custom_converters={A: custom_a_converter}
) == custom_a_converter(a)


def test_register_warning():
with pytest.warns(FreezeWarning):
cool.register(bytearray, bytes)

0 comments on commit 62393ad

Please sign in to comment.