Skip to content

Commit 290cdfc

Browse files
author
Christoph Lutz
committed
added lost test 'returncodes' and fixed return codes in clitests
return codes in clitests partly changed (and got quite better) after switching to new apt_repos.suppress_unwanted_apt_pkg_messages mechanism.
1 parent d8b7ad0 commit 290cdfc

File tree

2 files changed

+11
-8
lines changed

2 files changed

+11
-8
lines changed

Makefile

+3-4
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1-
run_test:
2-
make -C test test
1+
all: clean docs manpages tests
32

4-
run_clitests:
5-
make -C test clitests
3+
tests:
4+
make -C test
65

76
%.html: %.md
87
sed "s/\.md)/\.html)/g" $< | pandoc -s --css styles.css -f markdown -t html -o $@

test/Makefile

+8-4
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ UNIT_TESTCASES = testPrintHelloWorld \
2222
testRepository
2323
#UNIT_TESTCASES = testRepository
2424

25-
test: unittests clitests git_diff_results
25+
tests: unittests clitests git_diff_results returncodes
2626

2727
clitests: _cliTestHelpSystem _cliTestSuites _cliTestLs _cliTestShow _cliTestDsc _cliTestSource
2828

@@ -42,6 +42,10 @@ unittests: clean
4242
done
4343
$(FINISHED_TEST)
4444

45+
returncodes:
46+
$(IS_GIT_TREE) || exit 0
47+
make clitests IS_GIT_TREE=false
48+
4549
git_diff_results:
4650
$(IS_GIT_TREE) || exit 0
4751
$(STARTING_TEST)
@@ -58,7 +62,7 @@ clean:
5862

5963
_cliTestHelpSystem:
6064
$(STARTING_TEST)
61-
$(CLI) >cliHelpTest1.res 2>&1 $(EXP_OK)
65+
$(CLI) >cliHelpTest1.res 2>&1 $(EXP_FAIL)
6266
diff -u cliHelpTest1.ref cliHelpTest1.res $(EXP_OK)
6367

6468
$(CLI) -h >cliHelpTest2.res 2>&1 $(EXP_OK)
@@ -139,10 +143,10 @@ _cliTestDsc:
139143
$(CLI) dsc -s ubuntu: reprepro >cliTestDsc2.res 2>&1 $(EXP_OK)
140144
diff -u cliTestDsc2.ref cliTestDsc2.res $(EXP_OK)
141145

142-
$(CLI) dsc -s ubuntu: notexistent >cliTestDsc3.res 2>&1 $(EXP_FAIL)
146+
$(CLI) dsc -s ubuntu: notexistent >cliTestDsc3.res 2>&1 $(EXP_OK)
143147
diff -u cliTestDsc3.ref cliTestDsc3.res $(EXP_OK)
144148

145-
$(CLI) dsc -c main -s ubuntu: reprepro >cliTestDsc4.res 2>&1 $(EXP_FAIL)
149+
$(CLI) dsc -c main -s ubuntu: reprepro >cliTestDsc4.res 2>&1 $(EXP_OK)
146150
diff -u cliTestDsc4.ref cliTestDsc4.res $(EXP_OK)
147151

148152
$(CLI) dsc -c universe -s ubuntu: reprepro >cliTestDsc5.res 2>&1 $(EXP_OK)

0 commit comments

Comments
 (0)