Python testscenarios.multiply_scenarios() Examples

The following are 6 code examples of testscenarios.multiply_scenarios(). You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may also want to check out all available functions/classes of the module testscenarios , or try the search function .
Example #1
Source File: test_storage.py    From cloudkitty with Apache License 2.0 5 votes vote down vote up
def generate_scenarios(cls):
        cls.scenarios = testscenarios.multiply_scenarios(
            cls.scenarios,
            cls.storage_scenarios) 
Example #2
Source File: test_storage_unit.py    From cloudkitty with Apache License 2.0 5 votes vote down vote up
def generate_scenarios(cls):
        cls.scenarios = testscenarios.multiply_scenarios(
            cls.scenarios,
            cls.storage_scenarios) 
Example #3
Source File: api.py    From maas with GNU Affero General Public License v3.0 5 votes vote down vote up
def merge_scenarios(*scenario_lists):
    """Multiply `scenarios` together but ignoring empty or undefined ones."""
    scenario_lists = [
        scenarios
        for scenarios in scenario_lists
        if scenarios is not None and len(scenarios) != 0
    ]
    if len(scenario_lists) == 0:
        return None  # Ensure that testscenarios does not expand.
    elif len(scenario_lists) == 1:
        return scenario_lists[0]  # No need to multiply up.
    else:
        return multiply_scenarios(*scenario_lists) 
Example #4
Source File: test_imageutils.py    From oslo.utils with Apache License 2.0 5 votes vote down vote up
def generate_scenarios(cls):
        cls.scenarios = testscenarios.multiply_scenarios(
            cls._image_name,
            cls._file_format,
            cls._virtual_size,
            cls._disk_size,
            cls._garbage_before_snapshot,
            cls._snapshot_count) 
Example #5
Source File: test_imageutils.py    From oslo.utils with Apache License 2.0 5 votes vote down vote up
def generate_scenarios(cls):
        cls.scenarios = testscenarios.multiply_scenarios(
            cls._image_name,
            cls._file_format,
            cls._virtual_size,
            cls._disk_size,
            cls._garbage_before_snapshot,
            cls._snapshot_count,
            cls._qcow2_cluster_size,
            cls._qcow2_encrypted,
            cls._qcow2_backing_file) 
Example #6
Source File: test_strutils.py    From oslo.utils with Apache License 2.0 5 votes vote down vote up
def generate_scenarios(cls):
        cls.scenarios = testscenarios.multiply_scenarios(cls._unit_system,
                                                         cls._sign,
                                                         cls._magnitude,
                                                         cls._unit_prefix,
                                                         cls._unit_suffix,
                                                         cls._return_int)