-
Notifications
You must be signed in to change notification settings - Fork 7
YACHT-1133: deleted partition_id from dataset/list restore #101
Conversation
Do not merge, needs to fix tests |
Fixed unit tests.
@@ -111,24 +111,6 @@ def test_should_not_create_restore_items_for_deleted_backups(self): | |||
# then | |||
self.assertEqual(generated_restore_items, [[restore_item]]) | |||
|
|||
def test_should_create_restore_item_for_partition( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would left this tests, but edit what it expects.
We still use partitionId in source table, only we don't specified them for target. (it is how it was done in BackupCreator class - I believe we should do the same for restore also).
@@ -196,15 +178,13 @@ def __prepare_tables_which_should_be_returned_by_max_partition_days_query(): | |||
project_id=PROJECT_TO_RESTORE, | |||
dataset_id=DATASET_TO_RESTORE, | |||
table_id='tbl1', | |||
date=datetime(2017, 12, 6), | |||
partition_id='20171206' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
after change, your tests doesn't generate partitions in datastore.
In my opinion it should, we still want to test how our application works for partitioned table.
I deployed this commit on dev, then created copy jobs that restore partitioned table and it looks like it works without any errors. |
Pull Request Test Coverage Report for Build 928
💛 - Coveralls |
Potential solution. Need to be tested on dev.