MCPcopy Create free account
hub / github.com/bopen/xarray-sentinel / test_open_dataset_attitude

Function test_open_dataset_attitude

tests/test_30_xarray_backends.py:126–149  ·  view source on GitHub ↗
(
    product_path: esa_safe.PathType,
    swath_pol: str,
)

Source from the content-addressed store, hash-verified

124
125@pytest.mark.parametrize("product_path,swath_pol", SENTINEL1_PRODUCTS)
126def test_open_dataset_attitude(
127 product_path: esa_safe.PathType,
128 swath_pol: str,
129) -> None:
130 res = xr.open_dataset(
131 product_path, engine="sentinel-1", group=f"{swath_pol}/attitude"
132 )
133
134 assert isinstance(res, xr.Dataset)
135 assert set(res.sizes) == {"azimuth_time"}
136 expected = {
137 "azimuth_time",
138 "roll",
139 "pitch",
140 "yaw",
141 "q0",
142 "q1",
143 "q2",
144 "q3",
145 "wx",
146 "wy",
147 "wz",
148 }
149 assert set(res.variables) == expected
150
151
152@pytest.mark.parametrize("product_path,swath_pol", SENTINEL1_PRODUCTS)

Callers

nothing calls this directly

Calls 1

open_datasetMethod · 0.80

Tested by

no test coverage detected