Skip to content

Commit

Permalink
use real data in failing test
Browse files Browse the repository at this point in the history
  • Loading branch information
Dobson committed Jan 7, 2025
1 parent e1024d1 commit 539cdc1
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions tests/test_land.py
Original file line number Diff line number Diff line change
Expand Up @@ -1431,6 +1431,14 @@ def test_apply_surface_overrides(tmp_path):
import yaml
from wsimod.orchestration.model import Model

with (tmp_path / "fake_surface_inputs.csv").open("w") as f:
f.write("node,surface,variable,time,value\n")
f.write("land1,Woodland,srp-dry,2000-01-01,1\n")

with (tmp_path / "fake_inputs.csv").open("w") as f:
f.write("node,variable,time,value\n")
f.write("land1,et0,2000-01-01,1\n")

config = {
"arcs": {
"arc1": {
Expand All @@ -1447,23 +1455,23 @@ def test_apply_surface_overrides(tmp_path):
"name": "land1",
"type_": "Land",
"percolation_residence_time": 0.1,
"data_input_dict": {"fake-key": 1},
"filename": str(tmp_path / "fake_inputs.csv"),
"surfaces": {
"Woodland": {
"area": 100,
"datum": 10,
"type_": "GrowingSurface",
"ET_depletion_factor": 0.75,
"surface": "Woodland",
"data_input_dict": {"fake-key": 1},
"filename": str(tmp_path / "fake_surface_inputs.csv"),
},
"Grass": {
"area": 200,
"datum": 20,
"type_": "GrowingSurface",
"ET_depletion_factor": 0.75,
"surface": "Grass",
"data_input_dict": {"fake-key": 1},
"filename": str(tmp_path / "fake_surface_inputs.csv"),
},
},
},
Expand Down

0 comments on commit 539cdc1

Please sign in to comment.