Skip to content

Commit c30b8aa

Browse files
committed
Fix broken tests
1 parent 629b97c commit c30b8aa

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

tests/test_calibration.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,13 @@
1313
from nannyml.exceptions import InvalidArgumentsException
1414

1515

16+
@pytest.fixture(autouse=True)
17+
def calibrator_factory():
18+
# hack our way out of singleton side effects in tests.
19+
# we could replace this with a proper singleton pattern, but seems overkill for just tests?
20+
CalibratorFactory._registry = {'isotonic': IsotonicCalibrator}
21+
22+
1623
class DummyCalibrator(Mock):
1724
def __init__(self, **kwargs):
1825
super().__init__()

0 commit comments

Comments
 (0)