mirror of
https://github.com/finegrain-ai/refiners.git
synced 2024-11-21 21:58:47 +00:00
test_trainer: use model_copy
instead of copy
The `copy` method has been deprecated.
This commit is contained in:
parent
f4aa0271b8
commit
9aefc9896c
|
@ -82,7 +82,7 @@ def mock_trainer(mock_config: MockConfig) -> MockTrainer:
|
||||||
|
|
||||||
@pytest.fixture
|
@pytest.fixture
|
||||||
def mock_trainer_short(mock_config: MockConfig) -> MockTrainer:
|
def mock_trainer_short(mock_config: MockConfig) -> MockTrainer:
|
||||||
mock_config_short = mock_config.copy()
|
mock_config_short = mock_config.model_copy(deep=True)
|
||||||
mock_config_short.training.duration = {"number": 3, "unit": TimeUnit.STEP}
|
mock_config_short.training.duration = {"number": 3, "unit": TimeUnit.STEP}
|
||||||
return MockTrainer(config=mock_config_short)
|
return MockTrainer(config=mock_config_short)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue