From 3c31c01db40b584571e8f8bdb6ddc91cc36828cc Mon Sep 17 00:00:00 2001 From: William Pitcock Date: Fri, 20 Jul 2012 17:18:35 -0500 Subject: [PATCH] tests: add tests for malformed option arguments --- tests/run.sh.in | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tests/run.sh.in b/tests/run.sh.in index f46babc..77c4268 100644 --- a/tests/run.sh.in +++ b/tests/run.sh.in @@ -43,6 +43,10 @@ run_test "PKG_CONFIG_PATH=${selfdir}/lib1 ${1} --libs foo" \ '-lfoo' run_test "PKG_CONFIG_PATH=${selfdir}/lib1 ${1} --cflags --libs foo" \ '-lfoo' '-I/usr/include/foo' '-fPIC' +run_test "PKG_CONFIG_PATH=${selfdir}/lib1 ${1} --cflags --libs 'foo > 1.2'" \ + '-lfoo' '-I/usr/include/foo' '-fPIC' +run_test "PKG_CONFIG_PATH=${selfdir}/lib1 ${1} --cflags --libs 'foo' '>' '1.2'" \ + '-lfoo' '-I/usr/include/foo' '-fPIC' run_test "PKG_CONFIG_PATH=${selfdir}/lib1 ${1} --exists 'foo > 1.2'; echo \$?" \ '0' run_test "PKG_CONFIG_PATH=${selfdir}/lib1 ${1} --exists 'foo > 1.2.3'; echo \$?" \ @@ -75,6 +79,8 @@ run_test "PKG_CONFIG_PATH=${selfdir}/lib1 ${1} --libs dos-lineendings" \ '-L/usr/lib/dos-lineendings -ldos-lineendings' run_test "PKG_CONFIG_PATH=${selfdir}/lib1 ${1} --libs argv-parse" \ '-llib-2 -lpthread' +run_test "PKG_CONFIG_PATH=${selfdir}/lib1 ${1} --exists -foo; echo \$?" \ + '1' # 5) tests for other regressions run_test "PKG_CONFIG_PATH=${selfdir}/lib1 ${1} --variable=includedir foo" \