-
Notifications
You must be signed in to change notification settings - Fork 122
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use name and type comparising when appending a dataframe into table #14
Changes from 6 commits
631d66c
5dafd55
66aa616
45826f1
70d08ef
77b1fd5
bf8c378
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1161,6 +1161,34 @@ def test_upload_data_flexible_column_order(self): | |
_get_project_id(), if_exists='append', | ||
private_key=_get_private_key_path()) | ||
|
||
def test_verify_schema_ignores_field_mode(self): | ||
test_id = "14" | ||
test_schema_1 = {'fields': [{'name': 'A', | ||
'type': 'FLOAT', | ||
'mode': 'NULLABLE'}, | ||
{'name': 'B', | ||
'type': 'FLOAT', | ||
'mode': 'NULLABLE'}, | ||
{'name': 'C', | ||
'type': 'STRING', | ||
'mode': 'NULLABLE'}, | ||
{'name': 'D', | ||
'type': 'TIMESTAMP', | ||
'mode': 'REQUIRED'}]} | ||
test_schema_2 = {'fields': [{'name': 'A', | ||
'type': 'FLOAT'}, | ||
{'name': 'B', | ||
'type': 'FLOAT'}, | ||
{'name': 'C', | ||
'type': 'STRING'}, | ||
{'name': 'D', | ||
'type': 'TIMESTAMP'}]} | ||
|
||
self.table.create(TABLE_ID + test_id, test_schema_1) | ||
self.assertTrue(self.sut.verify_schema( | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. just use
the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. OK, I just looked the convention from the tests above. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. hah, I was going to change it on merge...but forgot...no worries |
||
self.dataset_prefix + "1", TABLE_ID + test_id, test_schema_2), | ||
'Expected schema to match') | ||
|
||
def test_list_dataset(self): | ||
dataset_id = self.dataset_prefix + "1" | ||
self.assertTrue(dataset_id in self.dataset.datasets(), | ||
|
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.
add
(:issue:`13`)
.