satpy.tests.scene_tests.test_load module

Unit tests for loading-related functionality in scene.py.

class satpy.tests.scene_tests.test_load.TestBadLoading[source]

Bases: object

Test the Scene object’s .load method with bad inputs.

pytestmark = [Mark(name='usefixtures', args=('include_test_etc',), kwargs={})]
test_load_no_exist()[source]

Test loading a dataset that doesn’t exist.

test_load_str()[source]

Test passing a string to Scene.load.

class satpy.tests.scene_tests.test_load.TestLoadingComposites[source]

Bases: object

Test the Scene object’s .load method for composites.

pytestmark = [Mark(name='usefixtures', args=('include_test_etc',), kwargs={})]
test_load_comp11_and_23()[source]

Test loading two composites that depend on similar wavelengths.

test_load_comp15()[source]

Test loading a composite whose prerequisites can’t be loaded.

Note that the prereq exists in the reader, but fails in loading.

test_load_comp17()[source]

Test loading a composite that depends on a composite that won’t load.

test_load_comp18()[source]

Test loading a composite that depends on an incompatible area modified dataset.

test_load_comp18_2()[source]

Test loading a composite that depends on an incompatible area modified dataset.

Specifically a modified dataset where the modifier has optional dependencies.

test_load_comp19()[source]

Test loading a composite that shares a dep with a dependency.

More importantly test that loading a dependency that depends on the same dependency as this composite (a sibling dependency) and that sibling dependency includes a modifier. This test makes sure that the Node in the dependency tree is the exact same node.

test_load_comp8()[source]

Test loading a composite that has a non-existent prereq.

test_load_dataset_after_composite()[source]

Test load composite followed by other datasets.

test_load_dataset_after_composite2()[source]

Test load complex composite followed by other datasets.

test_load_modified()[source]

Test loading a modified dataset.

test_load_modified_with_load_kwarg()[source]

Test loading a modified dataset using the Scene.load keyword argument.

test_load_multiple_comps()[source]

Test loading multiple composites.

test_load_multiple_comps_separate()[source]

Test loading multiple composites, one at a time.

test_load_multiple_modified()[source]

Test loading multiple modified datasets.

test_load_multiple_resolutions()[source]

Test loading a dataset has multiple resolutions available with different resolutions.

test_load_same_subcomposite()[source]

Test loading a composite and one of it’s subcomposites at the same time.

test_load_too_many()[source]

Test dependency tree if too many reader keys match.

test_load_when_sensor_none_in_preloaded_dataarrays()[source]

Test Scene loading when existing loaded arrays have sensor set to None.

Some readers or composites (ex. static images) don’t have a sensor and developers choose to set it to None. This test makes sure this doesn’t break loading.

test_modified_with_wl_dep()[source]

Test modifying a dataset with a modifier with modified deps.

More importantly test that loading the modifiers dependency at the same time as the original modified dataset that the dependency tree nodes are unique and that DataIDs.

test_no_generate_comp10()[source]

Test generating a composite after loading.

test_single_composite_loading(comp_name, exp_id_or_name)[source]

Test that certain composites can be loaded individually.

class satpy.tests.scene_tests.test_load.TestLoadingReaderDatasets[source]

Bases: object

Test the Scene object’s .load method for datasets coming from a reader.

pytestmark = [Mark(name='usefixtures', args=('include_test_etc',), kwargs={})]
test_load_ds1_load_twice()[source]

Test loading one dataset with no loaded compositors.

test_load_ds1_no_comps()[source]

Test loading one dataset with no loaded compositors.

test_load_ds1_unknown_modifier()[source]

Test loading one dataset with no loaded compositors.

test_load_ds4_cal()[source]

Test loading a dataset that has two calibration variations.

test_load_ds5_multiple_resolution_loads()[source]

Test loading a dataset with multiple resolutions available as separate loads.

test_load_ds5_variations(input_filenames, load_kwargs, exp_resolution)[source]

Test loading a dataset has multiple resolutions available.

test_load_ds6_wl()[source]

Test loading a dataset by wavelength.

test_load_ds9_fail_load()[source]

Test loading a dataset that will fail during load.

test_load_no_exist2()[source]

Test loading a dataset that doesn’t exist then another load.

class satpy.tests.scene_tests.test_load.TestSceneAllAvailableDatasets[source]

Bases: object

Test the Scene’s handling of various dependencies.

pytestmark = [Mark(name='usefixtures', args=('include_test_etc',), kwargs={})]
test_all_dataset_names_no_readers()[source]

Test all dataset names with no reader.

test_all_datasets_multiple_reader()[source]

Test all datasets for multiple readers.

test_all_datasets_no_readers()[source]

Test all datasets with no reader.

test_all_datasets_one_reader()[source]

Test all datasets for one reader.

test_available_composite_ids_missing_available()[source]

Test available_composite_ids when a composites dep is missing.

test_available_composites_known_versus_all()[source]

Test available_composite_ids when some datasets aren’t available.

test_available_comps_no_deps()[source]

Test Scene available composites when composites don’t have a dependency.

test_available_dataset_names_no_readers()[source]

Test the available dataset names without a reader.

test_available_dataset_no_readers()[source]

Test the available datasets without a reader.

test_available_datasets_one_reader()[source]

Test the available datasets for one reader.

test_available_when_sensor_none_in_preloaded_dataarrays()[source]

Test Scene available composites when existing loaded arrays have sensor set to None.

Some readers or composites (ex. static images) don’t have a sensor and developers choose to set it to None. This test makes sure this doesn’t break available composite IDs.

satpy.tests.scene_tests.test_load._data_array_none_sensor(name: str) DataArray[source]

Create a DataArray with sensor set to None.

satpy.tests.scene_tests.test_load._scene_with_data_array_none_sensor()[source]