def setUp(self):
original_intersect = nxos_db._get_free_vpcids_on_switches<EOL>def new_get_free_vpcids_on_switches(nexus_ips):<EOL><INDENT>intersect = list(original_intersect(nexus_ips))<EOL>intersect.sort()<EOL>return intersect<EOL><DEDENT>mock.patch.object(nxos_db,<EOL>'<STR_LIT>',<EOL>new=new_get_free_vpcids_on_switches).start()<EOL>cfg.CONF.set_override('<STR_LIT>', <NUM_LIT:0>, '<STR_LIT>')<EOL>super(TestCiscoNexusBaremetalDevice, self).setUp()<EOL>self.results = TestCiscoNexusBaremetalResults()<EOL>
Sets up mock driver, and switch and credentials dictionaries.