baremetal: Drop unused columns in bm_nodes
Drop these two columns: * bm_nodes.prov_vlan_id * bm_nodes.registration_status And update related code, tests and api_samples. Change-Id: Iadefc83a00ad9ae5a3bb39f357080299875bdf09
This commit is contained in:
		| @@ -32,9 +32,7 @@ def new_bm_node(**kwargs): | |||||||
|     h.pm_user = kwargs.pop('pm_user', 'ipmi_user') |     h.pm_user = kwargs.pop('pm_user', 'ipmi_user') | ||||||
|     h.pm_password = kwargs.pop('pm_password', 'ipmi_password') |     h.pm_password = kwargs.pop('pm_password', 'ipmi_password') | ||||||
|     h.prov_mac_address = kwargs.pop('prov_mac_address', '12:34:56:78:90:ab') |     h.prov_mac_address = kwargs.pop('prov_mac_address', '12:34:56:78:90:ab') | ||||||
|     h.registration_status = kwargs.pop('registration_status', 'done') |  | ||||||
|     h.task_state = kwargs.pop('task_state', None) |     h.task_state = kwargs.pop('task_state', None) | ||||||
|     h.prov_vlan_id = kwargs.pop('prov_vlan_id', None) |  | ||||||
|     h.terminal_port = kwargs.pop('terminal_port', 8000) |     h.terminal_port = kwargs.pop('terminal_port', 8000) | ||||||
|     if len(kwargs) > 0: |     if len(kwargs) > 0: | ||||||
|         raise test.TestingException("unknown field: %s" |         raise test.TestingException("unknown field: %s" | ||||||
|   | |||||||
| @@ -1238,3 +1238,9 @@ class TestBaremetalMigrations(BaseMigrationTestCase, CommonTestsMixIn): | |||||||
|     def _post_downgrade_004(self, engine): |     def _post_downgrade_004(self, engine): | ||||||
|         bm_nodes = get_table(engine, 'bm_nodes') |         bm_nodes = get_table(engine, 'bm_nodes') | ||||||
|         self.assertNotIn(u'instance_name', [c.name for c in bm_nodes.columns]) |         self.assertNotIn(u'instance_name', [c.name for c in bm_nodes.columns]) | ||||||
|  |  | ||||||
|  |     def _check_005(self, engine, data): | ||||||
|  |         bm_nodes = get_table(engine, 'bm_nodes') | ||||||
|  |         columns = [c.name for c in bm_nodes.columns] | ||||||
|  |         self.assertNotIn(u'prov_vlan_id', columns) | ||||||
|  |         self.assertNotIn(u'registration_status', columns) | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Arata Notsu
					Arata Notsu