~ubuntu-branches/ubuntu/wily/grass/wily

« back to all changes in this revision

Viewing changes to raster/r.colors/tests/test.r.colors.multiple.sh

Tags: 7.0.0~rc1+ds1-1~exp1
* New upstream release candidate.
* Repack upstream tarball, remove precompiled Python objects.
* Add upstream metadata.
* Update gbp.conf and Vcs-Git URL to use the experimental branch.
* Update watch file for GRASS 7.0.
* Drop build dependencies for Tcl/Tk, add build dependencies:
  python-numpy, libnetcdf-dev, netcdf-bin, libblas-dev, liblapack-dev
* Update Vcs-Browser URL to use cgit instead of gitweb.
* Update paths to use grass70.
* Add configure options: --with-netcdf, --with-blas, --with-lapack,
  remove --with-tcltk-includes.
* Update patches for GRASS 7.
* Update copyright file, changes:
  - Update copyright years
  - Group files by license
  - Remove unused license sections
* Add patches for various typos.
* Fix desktop file with patch instead of d/rules.
* Use minimal dh rules.
* Bump Standards-Version to 3.9.6, no changes.
* Use dpkg-maintscript-helper to replace directories with symlinks.
  (closes: #776349)
* Update my email to use @debian.org address.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# This script tests r.colors and r.colors.out
 
2
# Color rules are set with r.colors and exported using r.colors.out
 
3
 
 
4
# We specific a small region in the
 
5
# @preprocess step and generate
 
6
# raster data with r.mapcalc
 
7
# The region setting should work for UTM and LL test locations
 
8
g.region s=0 n=90 w=0 e=100 b=0 t=50 res=10 res3=10 -p3
 
9
# To test r.colors, we need several maps of different types
 
10
r.mapcalc --o expr="test_elev_double_1 = double(rand(-15.0, 5.0))"
 
11
r.mapcalc --o expr="test_elev_double_2 = double(rand(0.0, 10.0))"
 
12
r.mapcalc --o expr="test_elev_double_3 = double(rand(5.0, 15.0))"
 
13
 
 
14
r.mapcalc --o expr="test_elev_int_1 = int(rand(-15.0, 5.0))"
 
15
r.mapcalc --o expr="test_elev_int_2 = int(rand(0.0, 10.0))"
 
16
r.mapcalc --o expr="test_elev_int_3 = int(rand(5.0, 15.0))"
 
17
 
 
18
 
 
19
# First we @test the integer maps
 
20
# We use the examples to test the import, export and setting of color tables with different options
 
21
# the validation is based on raster map color rules @files.txterence files created with r.colors.out
 
22
r.colors    map=test_elev_int_1,test_elev_int_2,test_elev_int_3 \
 
23
            color=difference && r.colors.out --o map=test_elev_int_3 \
 
24
            rules=test_elev_int_maps_difference_1.txt
 
25
 
 
26
r.colors -e map=test_elev_int_1,test_elev_int_2,test_elev_int_3 \
 
27
            color=difference && r.colors.out --o map=test_elev_int_3 \
 
28
            rules=test_elev_int_maps_difference_hist.txt
 
29
 
 
30
r.colors -n map=test_elev_int_1,test_elev_int_2,test_elev_int_3 \
 
31
            color=difference && r.colors.out --o map=test_elev_int_3 \
 
32
            rules=test_elev_int_maps_difference_invert.txt
 
33
 
 
34
r.colors -a map=test_elev_int_1,test_elev_int_2,test_elev_int_3 \
 
35
            color=difference && r.colors.out --o map=test_elev_int_3 \
 
36
            rules=test_elev_int_maps_difference_logabsscale.txt
 
37
 
 
38
r.colors -g map=test_elev_int_2,test_elev_int_3 \
 
39
            color=difference && r.colors.out --o map=test_elev_int_3 \
 
40
            rules=test_elev_int_maps_difference_logscale.txt
 
41
 
 
42
r.colors    map=test_elev_int_1,test_elev_int_2,test_elev_int_3 \
 
43
            color=random && r.colors.out --o map=test_elev_int_3 \
 
44
            rules=test_elev_int_maps_random.txt
 
45
 
 
46
r.colors    map=test_elev_int_1,test_elev_int_2,test_elev_int_3 \
 
47
            color=grey.eq && r.colors.out --o map=test_elev_int_3 \
 
48
            rules=test_elev_int_maps_grey_eq.txt
 
49
 
 
50
r.colors    map=test_elev_int_2,test_elev_int_3 \
 
51
            color=grey.log && r.colors.out --o map=test_elev_int_3 \
 
52
            rules=test_elev_int_maps_grey_log.txt
 
53
 
 
54
# Tests with floating point maps
 
55
r.colors    map=test_elev_double_1,test_elev_double_2,test_elev_double_3 \
 
56
            color=difference && r.colors.out --o map=test_elev_double_3 \
 
57
            rules=test_elev_double_maps_difference_1.txt
 
58
 
 
59
r.colors -e map=test_elev_double_1,test_elev_double_2,test_elev_double_3 \
 
60
            color=difference && r.colors.out --o map=test_elev_double_3 \
 
61
            rules=test_elev_double_maps_difference_hist.txt
 
62
 
 
63
r.colors -n map=test_elev_double_1,test_elev_double_2,test_elev_double_3 \
 
64
            color=difference && r.colors.out --o map=test_elev_double_3 \
 
65
            rules=test_elev_double_maps_difference_invert.txt
 
66
 
 
67
r.colors -a map=test_elev_double_1,test_elev_double_2,test_elev_double_3 \
 
68
            color=difference && r.colors.out --o map=test_elev_double_3 \
 
69
            rules=test_elev_double_maps_difference_logabsscale.txt
 
70
 
 
71
r.colors -g map=test_elev_double_2,test_elev_double_3 \
 
72
            color=difference && r.colors.out --o map=test_elev_double_3 \
 
73
            rules=test_elev_double_maps_difference_logscale.txt