Skip to content

Commit

Permalink
Testing avg_losses too [ci skip]
Browse files Browse the repository at this point in the history
  • Loading branch information
micheles committed Dec 20, 2023
1 parent 10c084c commit 2384be9
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
7 changes: 7 additions & 0 deletions openquake/calculators/tests/classical_risk_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,13 @@ def test_case_5(self):

def test_case_master(self):
self.run_calc(case_master.__file__, 'job.ini')

# checking the avg_losses
[fname] = export(('avg_losses-stats', 'csv'), self.calc.datastore)
self.assertEqualFiles('expected/' + strip_calc_id(fname),
fname, delta=1E-5)

# checking the loss maps
fnames = export(('loss_maps-stats', 'csv'), self.calc.datastore)
assert fnames # sanity check
for fname in fnames:
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#,,,,,,,,"generated_by='OpenQuake engine 3.19.0-git10c084cb04', start_date='2023-12-20T17:13:17', checksum=2065913176, investigation_time=50.0, risk_investigation_time=50.0"
asset_id,taxonomy,lon,lat,business_interruption,contents,nonstructural,occupants,structural
a3,tax1,-122.57000,38.11300,9.27133E+00,6.15716E+01,8.29307E+01,1.85427E-04,3.11339E+01

0 comments on commit 2384be9

Please sign in to comment.