Opened 6 years ago
Last modified 5 years ago
#3822 new defect
Tests for r.basins.fill are broken
Reported by: | pmav99 | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | 7.8.3 |
Component: | Tests | Version: | svn-trunk |
Keywords: | Cc: | ||
CPU: | Unspecified | Platform: | Unspecified |
Description
These tests are broken both for python 2 and python 3:
raster/r.basins.fill/testsuite/testrbf.py
- http://fatra.cnr.ncsu.edu/grassgistests/reports_for_date-2019-03-26-07-00/report_for_nc_spm_full_v2alpha_nc/raster/r.basins.fill/testrbf/index.html
Moreover, the testsuite overwrites the "elevation" and "geology" maps thus ruining the test dataset (at least on python 3):
before running the tests:
./exec_grass.sh r.univar elevation Starting GRASS GIS... Cleaning up temporary files... Executing <r.univar elevation> ... 100% total null and non-null cells: 29535 total null cells: 0 Of the non-null cells: ---------------------- n: 29535 minimum: 89.6269 maximum: 134.301 range: 44.6739 mean: 116.855 mean of absolute values: 116.855 standard deviation: 9.32828 variance: 87.0169 variation coefficient: 7.98278 % sum: 3451315.7405014 Execution of <r.univar elevation> finished. Cleaning up default sqlite database ... Cleaning up temporary files...
after:
./exec_grass.sh r.univar elevation Starting GRASS GIS... Cleaning up temporary files... Executing <r.univar elevation> ... 100% total null and non-null cells: 29535 total null cells: 29535 Of the non-null cells: ---------------------- n: 0 minimum: -nan maximum: -nan range: -nan mean: -nan mean of absolute values: -nan standard deviation: -nan variance: -nan variation coefficient: -nan % sum: -nan Execution of <r.univar elevation> finished. Cleaning up default sqlite database ... Cleaning up temporary files...
Until someone finds the time to fix them, please add the following decorator on the Test class:
import unittest @unittest.skip("See #3822") class TestRasterbasin(TestCase): # ...
Attachments (1)
Change History (8)
by , 6 years ago
Attachment: | testrbf_fix_mapnames.diff added |
---|
follow-up: 2 comment:1 by , 6 years ago
After renaming the maps (see attached patch) the test passes here.
follow-up: 3 comment:2 by , 6 years ago
Replying to neteler:
After renaming the maps (see attached patch) the test passes here.
Does it make sense to adjust tests to a test location that is 1) not available, 2) in alpha state?
comment:3 by , 6 years ago
Replying to mmetz:
Replying to neteler:
After renaming the maps (see attached patch) the test passes here.
Does it make sense to adjust tests to a test location that is 1) not available,
It is available: http://fatra.cnr.ncsu.edu/data/
2) in alpha state?
In the end I only restored the names of the standard sample data set and found that the tests works.
comment:4 by , 6 years ago
After applying the patch, the tests do pass, but the "elevation" map still gets corrupted.
comment:6 by , 6 years ago
The test actually only tests if the module works, but contains additinal tests that have nothing to to with the module in question (and rather tests data or other modules). Took the liberty to deactivate the test until fixed with proper test cases.
comment:7 by , 5 years ago
Milestone: | → 7.8.3 |
---|
Update map names to those used in nc_spm_full_v2alpha