Exemplo n.º 1
0
    def setUp(self):
        super(EMCXIODriverFibreChannelTestCase, self).setUp()

        configuration = mock.Mock()
        configuration.san_login = ''
        configuration.san_password = ''
        configuration.san_ip = ''
        self.driver = XtremIOFibreChannelDriver(configuration=configuration)

        self.data = CommonData()
Exemplo n.º 2
0
    def setUp(self):
        super(EMCXIODriverFibreChannelTestCase, self).setUp()

        configuration = mock.Mock()
        configuration.san_login = ''
        configuration.san_password = ''
        configuration.san_ip = ''
        self.driver = XtremIOFibreChannelDriver(configuration=configuration)

        self.data = CommonData()
Exemplo n.º 3
0
class EMCXIODriverFibreChannelTestCase(test.TestCase):
    def setUp(self):
        super(EMCXIODriverFibreChannelTestCase, self).setUp()

        configuration = mock.Mock()
        configuration.san_login = ""
        configuration.san_password = ""
        configuration.san_ip = ""
        self.driver = XtremIOFibreChannelDriver(configuration=configuration)

        self.data = CommonData()

    def test_initialize_terminate_connection(self, req):
        req.side_effect = xms_request
        clean_xms_data()
        self.driver.create_volume(self.data.test_volume)
        map_data = self.driver.initialize_connection(self.data.test_volume, self.data.connector)
        self.assertEqual(map_data["data"]["target_lun"], 1)
        self.driver.terminate_connection(self.data.test_volume, self.data.connector)
        self.driver.delete_volume(self.data.test_volume)
Exemplo n.º 4
0
class EMCXIODriverFibreChannelTestCase(test.TestCase):
    def setUp(self):
        super(EMCXIODriverFibreChannelTestCase, self).setUp()

        configuration = mock.Mock()
        configuration.san_login = ''
        configuration.san_password = ''
        configuration.san_ip = ''
        self.driver = XtremIOFibreChannelDriver(configuration=configuration)

        self.data = CommonData()

    def test_initialize_terminate_connection(self, req):
        req.side_effect = xms_request
        clean_xms_data()
        self.driver.create_volume(self.data.test_volume)
        map_data = self.driver.initialize_connection(self.data.test_volume,
                                                     self.data.connector)
        self.assertEqual(map_data['data']['target_lun'], 1)
        self.driver.terminate_connection(self.data.test_volume,
                                         self.data.connector)
        self.driver.delete_volume(self.data.test_volume)