Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v.what.rast3: Rename test folder and fix execution of test #3362

Merged
merged 2 commits into from
Jan 26, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 0 additions & 40 deletions vector/v.what.rast3/test_suite/random_points.txt

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,28 @@ r3.mapcalc --o expr="plume = double(col() + row() + depth())"
# v.random --o -z seed=1 output=random_points npoints=10 zmin=0 zmax=50
# v.out.ascii --o format=standard input=random_points output=random_points.txt

v.in.ascii --o -z format=standard input=random_points.txt output=random_points
v.in.ascii --o -z format=standard input=data/random_points.ref output=random_points
v.out.ascii --o format=standard input=random_points > data/random_points.txt
echoix marked this conversation as resolved.
Show resolved Hide resolved
echoix marked this conversation as resolved.
Show resolved Hide resolved
v.db.addtable --o map=random_points column="concentration double precision"

# @test the voxel sampling with vector points
v.what.rast3 map=random_points raster3d=plume column=concentration
v.db.select map=random_points > data/random_points_db.txt

# Some data export commands for reference data creation and visual validation
#v.out.ascii --o format=standard input=random_points output=random_points.ref
#v.db.select map=random_points > random_points_db.ref
#r3.out.vtk --o input=plume output=plume.vtk null=0
#v.out.vtk --o -n input=random_points output=random_points.vtk


cd data

for i in `ls *.txt` ; do
diff $i "`basename $i .txt`.ref" >> out.diff
done

CHAR_NUM=`cat out.diff | wc -c`

# Return as exit status 0 in case no diffs are found
exit $CHAR_NUM
Loading