aboutsummaryrefslogtreecommitdiffstats
path: root/test/04_search
diff options
context:
space:
mode:
authorgramanas <anastasis.gramm2@gmail.com>2018-10-23 17:42:28 +0300
committergramanas <anastasis.gramm2@gmail.com>2018-10-23 17:42:28 +0300
commit46421fedf6fe291bfcb63482f3bfa9bb2c7fdff6 (patch)
tree53d85f05c362230a428ca5593125ba1a1341799d /test/04_search
parent410bb2715ce7c9f8d796704395cb44d76e2e884c (diff)
downloadck-46421fedf6fe291bfcb63482f3bfa9bb2c7fdff6.tar.gz
ck-46421fedf6fe291bfcb63482f3bfa9bb2c7fdff6.tar.bz2
ck-46421fedf6fe291bfcb63482f3bfa9bb2c7fdff6.zip
Remove site clutter and rename test folder (tests -> test)
Diffstat (limited to 'test/04_search')
-rw-r--r--test/04_search22
1 files changed, 22 insertions, 0 deletions
diff --git a/test/04_search b/test/04_search
new file mode 100644
index 0000000..c3600c1
--- /dev/null
+++ b/test/04_search
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+init search
+
+# setup test configs
+path1=$BIN/test1.conf
+path2=$BIN/test2.conf
+path3=$BIN/test3.conf
+path4=$BIN/test4.conf
+
+add_config prog1 $path1 "search-term"
+add_config prog1 $path2 "search-term"
+add_config prog2 $path3 "search-term"
+add_config prog3 $path4 "search-term"
+
+# delete path1
+if [[ $($BIN/ck -c $BIN search search-term | wc -l) != 4 ]]; then
+ err "search failed."
+fi
+
+clear_tests
+echo -e $PASS