Skip to content

Commit

Permalink
Move general use cube fixtures together.
Browse files Browse the repository at this point in the history
  • Loading branch information
truth-quark committed Oct 1, 2024
1 parent 8cf02c8 commit e4ca35c
Showing 1 changed file with 23 additions and 23 deletions.
46 changes: 23 additions & 23 deletions test/test_um2netcdf.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,29 @@ def geo_potential_cube(lat_v_nd_coord, lon_u_nd_coord):
return geo_potential


@pytest.fixture
def ua_plev_cube():
return DummyCube(30201, "ua_plev")


@pytest.fixture
def heaviside_uv_cube(lat_v_nd_coord, lon_u_nd_coord):
return DummyCube(30301, "heaviside_uv",
coords=[lat_v_nd_coord, lon_u_nd_coord])


@pytest.fixture
def ta_plev_cube(lat_v_nd_coord, lon_u_nd_coord):
return DummyCube(30204, "ta_plev",
coords=[lat_v_nd_coord, lon_u_nd_coord])


@pytest.fixture
def heaviside_t_cube(lat_standard_eg_coord, lon_standard_eg_coord):
return DummyCube(30304, "heaviside_t",
coords=[lat_standard_eg_coord, lon_standard_eg_coord])


@pytest.fixture
def std_args():
# TODO: make args namedtuple?
Expand Down Expand Up @@ -379,29 +402,6 @@ def coord(self, _name):
raise CoordinateNotFoundError(msg)


@pytest.fixture
def ua_plev_cube():
return DummyCube(30201, "ua_plev")


@pytest.fixture
def heaviside_uv_cube(lat_v_nd_coord, lon_u_nd_coord):
return DummyCube(30301, "heaviside_uv",
coords=[lat_v_nd_coord, lon_u_nd_coord])


@pytest.fixture
def ta_plev_cube(lat_v_nd_coord, lon_u_nd_coord):
return DummyCube(30204, "ta_plev",
coords=[lat_v_nd_coord, lon_u_nd_coord])


@pytest.fixture
def heaviside_t_cube(lat_standard_eg_coord, lon_standard_eg_coord):
return DummyCube(30304, "heaviside_t",
coords=[lat_standard_eg_coord, lon_standard_eg_coord])


# cube filtering tests
# NB: wrap results in tuples to capture generator output in sequences

Expand Down

0 comments on commit e4ca35c

Please sign in to comment.