Browse Source

testenv: test for exit status of "uci export".

Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
Yousong Zhou 9 years ago
parent
commit
90ba7cac9d
1 changed files with 8 additions and 0 deletions
  1. 8 0
      test/tests.d/010_export

+ 8 - 0
test/tests.d/010_export

@@ -1,6 +1,14 @@
 test_export ()
 {
 	cp ${REF_DIR}/export.data ${CONFIG_DIR}/export
+
+	${UCI_Q} export nilpackage
+	assertFalse $?
+
+	${UCI_Q} export export 1>/dev/null 2>&1
+	assertTrue $?
+
 	${UCI} export > ${TMP_DIR}/export.result
+	assertTrue $?
 	assertSameFile ${REF_DIR}/export.result ${TMP_DIR}/export.result
 }