satpy.tests.reader_tests.test_seviri_l1b_nc module

The HRIT msg reader tests package.

class satpy.tests.reader_tests.test_seviri_l1b_nc.TestNCSEVIRIFileHandler[source]

Bases: TestFileHandlerCalibrationBase

Unit tests for SEVIRI netCDF reader.

_get_fake_dataset(counts, h5netcdf)[source]

Create a fake dataset.

Parameters:
  • counts (xr.DataArray) – Array with data.

  • h5netcdf (boolean) – If True an array attribute will be created which is common for the h5netcdf backend in xarray for scalar values.

file_handler(counts, h5netcdf)[source]

Create a mocked file handler.

h5netcdf()[source]

Fixture for xr backend choice.

test_calibrate(file_handler, channel, calibration, use_ext_coefs)[source]

Test the calibration.

test_get_dataset(file_handler, channel, calibration, mask_bad_quality_scan_lines)[source]

Test getting the dataset.

test_h5netcdf_pecularity(file_handler, h5netcdf)[source]

Test conversion of attributes when xarray is used with h5netcdf backend.

test_mask_bad_quality(file_handler)[source]

Test masking of bad quality scan lines.

test_repeat_cycle_duration(file_handler)[source]

Test repeat cycle handling for FD or ReduscedScan.

test_satpos_no_valid_orbit_polynomial(file_handler)[source]

Test satellite position if there is no valid orbit polynomial.

test_time(file_handler)[source]

Test start/end nominal/observation time handling.

satpy.tests.reader_tests.test_seviri_l1b_nc.to_cds_time(time)[source]

Convert datetime to (days, msecs) since 1958-01-01.