Skip to content

Commit

Permalink
Start adding tests
Browse files Browse the repository at this point in the history
  • Loading branch information
dcherian committed Jan 19, 2021
1 parent abcc008 commit f1da0c0
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions xarray/tests/test_plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -2152,6 +2152,29 @@ def test_wrong_num_of_dimensions(self):
self.darray.plot.line(row="row", hue="hue")


@requires_matplotlib
class TestDatasetQuiverPlots(PlotTestCase):
@pytest.fixture(autouse=True)
def setUp(self):
das = [
DataArray(
np.random.randn(3, 3, 4, 4),
dims=["x", "row", "col", "hue"],
coords=[range(k) for k in [3, 3, 4, 4]],
)
for _ in [1, 2]
]
ds = Dataset({"A": das[0], "B": das[1]})
ds.hue.name = "huename"
ds.hue.attrs["units"] = "hunits"
ds.x.attrs["units"] = "xunits"
ds.col.attrs["units"] = "colunits"
ds.row.attrs["units"] = "rowunits"
ds.A.attrs["units"] = "Aunits"
ds.B.attrs["units"] = "Bunits"
self.ds = ds


@requires_matplotlib
class TestDatasetScatterPlots(PlotTestCase):
@pytest.fixture(autouse=True)
Expand Down

0 comments on commit f1da0c0

Please sign in to comment.