コード例 #1
0
 def test_exclude_devices_with_spaces(self):
     cfg.CONF.set_override('exclude_devices',
                           self.EXCLUDE_DEVICES_WITH_SPACES_LIST,
                           'SRIOV_NIC')
     exclude_devices = config.parse_exclude_devices(
         cfg.CONF.SRIOV_NIC.exclude_devices)
     self.assertEqual(exclude_devices, self.EXCLUDE_DEVICES)
コード例 #2
0
 def test_exclude_devices_with_spaces(self):
     cfg.CONF.set_override('exclude_devices',
                           self.EXCLUDE_DEVICES_WITH_SPACES_LIST,
                           'SRIOV_NIC')
     exclude_devices = config.parse_exclude_devices(
         cfg.CONF.SRIOV_NIC.exclude_devices)
     self.assertEqual(exclude_devices, self.EXCLUDE_DEVICES)
コード例 #3
0
ファイル: sriov_nic_agent.py プロジェクト: yangxu2014/neutron
    def parse(self):
        """Parses device_mappings and exclude_devices.

        Parse and validate the consistency in both mappings
        """
        self.device_mappings = q_utils.parse_mappings(
            cfg.CONF.SRIOV_NIC.physical_device_mappings)
        self.exclude_devices = config.parse_exclude_devices(
            cfg.CONF.SRIOV_NIC.exclude_devices)
        self._validate()
コード例 #4
0
ファイル: sriov_nic_agent.py プロジェクト: nnusun/neutron
    def parse(self):
        """Parses device_mappings and exclude_devices.

        Parse and validate the consistency in both mappings
        """
        self.device_mappings = q_utils.parse_mappings(
            cfg.CONF.SRIOV_NIC.physical_device_mappings)
        self.exclude_devices = config.parse_exclude_devices(
            cfg.CONF.SRIOV_NIC.exclude_devices)
        self._validate()