Skip to content

Commit

Permalink
data-mappings for congo, test for aws-template
Browse files Browse the repository at this point in the history
  • Loading branch information
maaikelimper committed Sep 14, 2023
1 parent feca565 commit 1f3f0f7
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 3 deletions.
24 changes: 23 additions & 1 deletion tests/data/data-mappings.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,40 @@
data:
cog.brazza_met_centre.data.core.weather.surface-based-observations.synop:
plugins:
bufr:
- plugin: wis2box.data.bufr4.ObservationDataBUFR
notify: true
buckets:
- ${WIS2BOX_STORAGE_INCOMING}
file-pattern: '^.*\.bufr$'
txt:
- plugin: wis2box.data.synop2bufr_api.ObservationDataSYNOP2BUFR
notify: true
file-pattern: '^.*_(\d{4})(\d{2}).*\.txt$'
bufr4:
- plugin: wis2box.data.bufr2geojson.ObservationDataBUFR2GeoJSON
buckets:
- ${WIS2BOX_STORAGE_PUBLIC}
file-pattern: '^.*\.bufr4$'
rou.rnimh.data.core.weather.surface-based-observations.synop:
plugins:
txt:
- plugin: wis2box.data.synop2bufr.ObservationDataSYNOP2BUFR
notify: true
file-pattern: '^A_SMR.*EDZW_(\d{4})(\d{2}).*.txt$'
csv:
- plugin: wis2box.data.csv2bufr.ObservationDataCSV2BUFR
template: aws-template
notify: true
file-pattern: '^.*\.csv$'
bufr4:
- plugin: wis2box.data.bufr2geojson.ObservationDataBUFR2GeoJSON
file-pattern: '^A_SMR.*EDZW_(\d{4})(\d{2}).*.bufr4$'
mwi.mwi_met_centre.data.core.weather.surface-based-observations.synop:
plugins:
csv:
- plugin: wis2box.data.csv2bufr.ObservationDataCSV2BUFR
template: /data/wis2box/synop_bufr.json
template: synop_bufr
notify: true
file-pattern: '^WIGOS_(\d-\d+-\d+-\w+)_.*\.csv$'
bufr4:
Expand Down
5 changes: 3 additions & 2 deletions tests/integration/test_workflow.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ def test_message_api():
'mwi_met_centre': 24,
'roma_met_centre': 33,
'alger_met_centre': 29,
'rnimh': 223,
'rnimh': 226,
'brazza_met_centre': 14
}
for key, value in counts.items():
Expand All @@ -207,7 +207,8 @@ def test_message_api():
url = f'{API_URL}/collections/messages/items?sortby=-datetime'
r = SESSION.get(url).json()

assert r['numberMatched'] == 323
# should match sum of counts above
assert r['numberMatched'] == 326

msg = r['features'][4]

Expand Down

0 comments on commit 1f3f0f7

Please sign in to comment.