File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
tests/unit/butterfree/_cli Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 9
9
10
10
11
11
def test_migrate_success (mocker ):
12
- migrate .Migrate . run = mocker . stub ( "migration " )
12
+ mocker . patch . object ( migrate .Migrate , "run " )
13
13
all_fs = migrate .migrate ("tests/mocks/entities/" )
14
14
assert all (isinstance (fs , FeatureSetPipeline ) for fs in all_fs )
15
15
assert sorted ([fs .feature_set .name for fs in all_fs ]) == ["first" , "second" ]
16
16
17
17
18
18
def test_migrate_all_pairs (mocker ):
19
- MetastoreMigration . apply_migration = mocker .stub ( "metastore_apply " )
20
- CassandraMigration . apply_migration = mocker .stub ( "cassandra_apply " )
19
+ mocker .patch . object ( MetastoreMigration , "apply_migration " )
20
+ mocker .patch . object ( CassandraMigration , "apply_migration " )
21
21
all_fs = migrate .migrate ("tests/mocks/entities/" )
22
22
23
23
assert MetastoreMigration .apply_migration .call_count == 2
You can’t perform that action at this time.
0 commit comments