Exemple #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)
 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)
    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()
Exemple #4
0
    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()