mirror of
git://projects.qi-hardware.com/wernermisc.git
synced 2025-04-21 12:27:27 +03:00
qpkg: test for the QPKG_ADDING leakage bug
- test/bug-adding: test if we get a false cyclic dependency because QPKG_ADDING isn't properly removed - TODO: mention the problem
This commit is contained in:
44
qpkg/test/bug-adding
Executable file
44
qpkg/test/bug-adding
Executable file
@@ -0,0 +1,44 @@
|
||||
#!/bin/sh
|
||||
. ./Common
|
||||
|
||||
###############################################################################
|
||||
|
||||
#
|
||||
# See the comment at the end of "resolve" in prereq.c for details.
|
||||
#
|
||||
|
||||
qpkg_fail "BUG: we don't clean up QPKG_ADDING, yielding false errors" \
|
||||
prereq A <<EOF
|
||||
Package: D
|
||||
Version: 0
|
||||
Architecture: test
|
||||
Conflicts: B (= 1)
|
||||
Filename: D_0
|
||||
|
||||
Package: C
|
||||
Version: 0
|
||||
Architecture: test
|
||||
Depends: D
|
||||
Filename: C_0
|
||||
|
||||
Package: B
|
||||
Version: 1
|
||||
Architecture: test
|
||||
Depends: C
|
||||
Filename: B_1
|
||||
|
||||
Package: B
|
||||
Version: 0
|
||||
Architecture: test
|
||||
Depends: C
|
||||
Filename: B_0
|
||||
|
||||
Package: A
|
||||
Version: 0
|
||||
Architecture: test
|
||||
Depends: B
|
||||
Filename: A_0
|
||||
EOF
|
||||
expect <<EOF
|
||||
package C version 0 has cyclic dependency
|
||||
EOF
|
||||
Reference in New Issue
Block a user