Skip to content

Commit

Permalink
Update test
Browse files Browse the repository at this point in the history
  • Loading branch information
samueljackson92 committed Aug 15, 2024
1 parent a28a26b commit 0d774e5
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion tests/test_transforms.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import numpy as np
import xarray as xr
from src.transforms import (
AddXSXCameraParams,
Expand Down Expand Up @@ -85,7 +86,14 @@ def test_standardise_dataset(fake_dataset):
assert "plasma_current_error" in dataset.data_vars


def test_xsx_camera_params(fake_dataset):
def test_xsx_camera_params():
fake_dataset = xr.Dataset(
data_vars=dict(
tcam=(("time", 'tcam_channels'), np.random.random((100, 18))),
time=("time", np.random.random(100)),
),
attrs={"name": "xsx/tcam", "shot_id": 30420},
)
transform = AddXSXCameraParams("tcam", "parameters/xsx_camera_t.csv")
dataset = transform(fake_dataset)

Expand Down

0 comments on commit 0d774e5

Please sign in to comment.