Skip to content

Commit 36b25ff

Browse files
authored
Merge pull request #1605 from knutfrode/dev
[run-ex] Added new oil type TYRVING
2 parents b8904da + 8ab40d6 commit 36b25ff

File tree

4 files changed

+16
-1
lines changed

4 files changed

+16
-1
lines changed

opendrift/models/openoil/adios/max_water_fraction.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1345,6 +1345,17 @@
13451345
0.74
13461346
]
13471347
},
1348+
"TYRVING 2025": {
1349+
"temperatures": [
1350+
5.0,
1351+
15.0
1352+
],
1353+
"max_water_fraction": [
1354+
0.79,
1355+
0.80
1356+
]
1357+
},
1358+
13481359
"ULA 1999": {
13491360
"temperatures": [
13501361
5.0,
224 Bytes
Binary file not shown.

tests/models/openoil/test_oil_list.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,12 @@ def test_get_openoil_list(test_data):
1515
def test_get_openoil_list_norway(test_data):
1616
# previous oils
1717
previous_oils_file = Path(test_data) / 'generated' / 'oil_list_norway.txt'
18+
1819
with open(previous_oils_file, 'r') as fd:
1920
previous_oils = [o.strip() for o in fd.readlines()]
2021

22+
assert 'TYRVING 2025' in previous_oils
23+
2124
o = OpenOil(location = 'NORWAY')
2225

2326
new_oils = set(o.oiltypes) - set(previous_oils)
@@ -33,7 +36,7 @@ def test_get_openoil_list_norway(test_data):
3336
for ot in removed_oils:
3437
print(ot)
3538

36-
if False: # Change to True when updating list of oils
39+
if True: # Change to True when updating list of oils
3740
print(f'Writing present list of oiltypes to {previous_oils_file}')
3841
with open(previous_oils_file, 'w') as f:
3942
for oil in o.oiltypes:

tests/test_data/generated/oil_list_norway.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,7 @@ TROLL, STATOIL
159159
TRYM KONDENSAT 2011
160160
TYRIHANS NORD 2004
161161
TYRIHANS SOR 2004
162+
TYRVING 2025
162163
ULA 1999
163164
ULTRA LOW SULFUR FUEL OIL 2017
164165
UTGARD CONDENSATE 2021

0 commit comments

Comments
 (0)