]> git.saurik.com Git - apt.git/blame - test/integration/test-external-dependency-solver-protocol
testcases: do not allow warnings in testsuccess
[apt.git] / test / integration / test-external-dependency-solver-protocol
CommitLineData
1f6cf9e7
DK
1#!/bin/sh
2set -e
3
4TESTDIR=$(readlink -f $(dirname $0))
5. $TESTDIR/framework
6setupenvironment
7configarchitecture 'amd64' 'i386'
8
9insertinstalledpackage 'cool' 'all' '1'
10insertinstalledpackage 'stuff' 'all' '1'
11
12insertpackage 'unstable' 'cool' 'all' '2' 'Multi-Arch: foreign'
13insertpackage 'unstable' 'stuff' 'all' '2' 'Multi-Arch: foreign'
14insertpackage 'unstable' 'coolstuff' 'i386,amd64' '2' 'Depends: cool, stuff'
15insertpackage 'unstable' 'awesome' 'all' '2' 'Multi-Arch: foreign'
16insertpackage 'unstable' 'awesomecoolstuff' 'i386' '2' 'Depends: coolstuff, awesome'
17
18insertpackage 'experimental' 'cool' 'all' '3' 'Multi-Arch: foreign'
19insertpackage 'experimental' 'stuff' 'all' '3' 'Multi-Arch: foreign'
20insertpackage 'experimental' 'coolstuff' 'i386,amd64' '3' 'Depends: cool, stuff'
21
22setupaptarchive
23
24rm -f /tmp/dump.edsp
25testequal 'Reading package lists...
26Building dependency tree...
27Execute external solver...
28The solver encountered an error of type: ERR_JUST_DUMPING
29The following information might help you to understand what is wrong:
30I am too dumb, i can just dump!
31Please use one of my friends instead!
32
33E: External solver failed with: I am too dumb, i can just dump!' aptget install --solver dump coolstuff -s
34testsuccess test -s /tmp/dump.edsp
35rm -f /tmp/dump.edsp
36
37#FIXME: this should be unstable, but we don't support pinning yet
38testequal 'Reading package lists...
39Building dependency tree...
40Execute external solver...
41The following NEW packages will be installed:
42 coolstuff
430 upgraded, 1 newly installed, 0 to remove and 2 not upgraded.
44Inst coolstuff (3 experimental [amd64])
45Conf coolstuff (3 experimental [amd64])' aptget install --solver apt coolstuff -s
46
47testsuccess aptget install awesomecoolstuff:i386 -s
48testsuccess aptget install --solver apt awesomecoolstuff:i386 -s
49
50rm -f /tmp/dump.edsp
51testfailure aptget install --solver dump awesomecoolstuff:i386 -s
52testsuccess test -s /tmp/dump.edsp
53
172947cd
DK
54testsuccess aptget dist-upgrade -s
55testsuccess aptget dist-upgrade -s --solver apt
56
57testsuccess aptget upgrade -s
58testsuccess aptget upgrade -s --solver apt
59
1f6cf9e7
DK
60configarchitecture 'armel'
61msgtest 'Test direct calling is okay for' 'apt-internal-solver'
686b484b 62cat /tmp/dump.edsp | aptinternalsolver > solver.result 2>&1 || true
1f6cf9e7
DK
63if [ "$(tail -n2 solver.result | head -n1 )" = "Message: Done" ]; then
64 msgpass
65else
66 cat solver.result
67 msgfail
68fi
69rm -f /tmp/dump.edsp
70
71testfailure aptget install --solver apt awesomecoolstuff:i386 -s