summaryrefslogtreecommitdiff
path: root/SConstruct
diff options
context:
space:
mode:
authorGary E. Miller <gem@rellim.com>2019-02-21 15:13:28 -0800
committerGary E. Miller <gem@rellim.com>2019-02-21 15:13:28 -0800
commitc40b62c5b409aa97acfa397e94dfb40198c62ea0 (patch)
tree63ad985e1efb15587eecb811cdc876d7268f93f4 /SConstruct
parent83e111fa7b4467500de853b790157e75f88bb64a (diff)
downloadgpsd-c40b62c5b409aa97acfa397e94dfb40198c62ea0.tar.gz
deg_to_s(): Fix bad conversion. Add test cases.
Bug and test case by: Stephen Moshier <steve@moshier.net>
Diffstat (limited to 'SConstruct')
-rw-r--r--SConstruct20
1 files changed, 18 insertions, 2 deletions
diff --git a/SConstruct b/SConstruct
index c9a76957..bd63541f 100644
--- a/SConstruct
+++ b/SConstruct
@@ -1377,6 +1377,9 @@ test_float = env.Program('tests/test_float', ['tests/test_float.c'])
test_geoid = env.Program('tests/test_geoid', ['tests/test_geoid.c'],
LIBS=['gpsd', 'gps_static'],
parse_flags=gpsdflags)
+test_gpsdclient = env.Program('tests/test_gpsdclient',
+ ['tests/test_gpsdclient.c'],
+ LIBS=['gps_static', 'm'])
test_matrix = env.Program('tests/test_matrix', ['tests/test_matrix.c'],
LIBS=['gpsd', 'gps_static'],
parse_flags=gpsdflags)
@@ -1408,8 +1411,16 @@ else:
test_gpsmm = env.Program('tests/test_gpsmm', ['tests/test_gpsmm.cpp'],
LIBS=['gps_static'],
parse_flags=["-lm"] + rtlibs + dbusflags)
-testprogs = [test_bits, test_float, test_geoid, test_libgps, test_matrix,
- test_mktime, test_packet, test_timespec, test_trig]
+testprogs = [test_bits,
+ test_float,
+ test_geoid,
+ test_gpsdclient,
+ test_libgps,
+ test_matrix,
+ test_mktime,
+ test_packet,
+ test_timespec,
+ test_trig]
if env['socket_export']:
testprogs.append(test_json)
if env["libgpsmm"]:
@@ -2050,6 +2061,11 @@ bits_regress = Utility('bits-regress', [test_bits], [
'$SRCDIR/tests/test_bits --quiet'
])
+# Unit-test the deg_to_str() extractor
+bits_regress = Utility('deg-regress', [test_gpsdclient], [
+ '$SRCDIR/tests/test_gpsdclient'
+])
+
# Unit-test the bitfield extractor
matrix_regress = Utility('matrix-regress', [test_matrix], [
'$SRCDIR/tests/test_matrix --quiet'