Esempio n. 1
0
    def setUp(self):
        super(TestOpencontrailDriver, self).setUp()

        self.nc_ports = mock.patch(
            'ceilometer.neutron_client'
            '.Client.port_get_all',
            return_value=self.fake_ports())
        self.nc_ports.start()

        self.nc_networks = mock.patch(
            'ceilometer.neutron_client'
            '.Client.network_get_all',
            return_value=self.fake_networks())
        self.nc_networks.start()

        self.driver = driver.OpencontrailDriver()
        self.parse_url = url_parse.ParseResult('opencontrail',
                                               '127.0.0.1:8143', '/', None,
                                               None, None)
        self.params = {
            'password': ['admin'],
            'scheme': ['http'],
            'username': ['admin'],
            'verify_ssl': ['false']
        }
Esempio n. 2
0
    def setUp(self):
        super(TestOpencontrailDriver, self).setUp()

        self.nc_ports = mock.patch('ceilometer.neutron_client'
                                   '.Client.port_get_all',
                                   return_value=self.fake_ports())
        self.nc_ports.start()

        self.CONF = self.useFixture(fixture_config.Config()).conf
        self.driver = driver.OpencontrailDriver(self.CONF)
        self.parse_url = urlparse.ParseResult('opencontrail',
                                              '127.0.0.1:8143',
                                              '/', None, None, None)
        self.params = {'password': ['admin'],
                       'scheme': ['http'],
                       'username': ['admin'],
                       'verify_ssl': ['false'],
                       'resource': ['if_stats_list']}