tests: add test for another kind of versioned soname bump.

This fails currently... working in a solution that works globally.
This commit is contained in:
Juan RP 2015-01-17 03:19:45 +01:00
parent e438aae13c
commit 757d1bda68

View File

@ -155,9 +155,42 @@ shlib_bump_revdep_diff_body() {
atf_check_equal $? 0
}
atf_test_case shlib_bump_versioned
shlib_bump_versioned_head() {
atf_set "descr" "Tests for pkg updates: revdep requires an unexistent versioned shlib"
}
shlib_bump_versioned_body() {
mkdir -p repo pkg
cd repo
xbps-create -A noarch -n A-1.0_1 -s "A pkg" --shlib-provides "liba-0.so" ../pkg
atf_check_equal $? 0
xbps-create -A noarch -n B-1.0_1 -s "B pkg" --dependencies "A>=0" --shlib-requires "liba-0.so" ../pkg
atf_check_equal $? 0
xbps-rindex -d -a $PWD/*.xbps
atf_check_equal $? 0
cd ..
xbps-install -C empty.conf -r root --repository=$PWD/repo -yvd B
atf_check_equal $? 0
cd repo
xbps-create -A noarch -n A-2.0_1 -s "A pkg" --shlib-provides "liba-1.so" ../pkg
atf_check_equal $? 0
xbps-rindex -d -a $PWD/*.xbps
atf_check_equal $? 0
cd ..
xbps-install -C empty.conf -r root --repository=$PWD/repo -yuvd
# ENOEXEC == unresolved shlibs
atf_check_equal $? 8
}
atf_init_test_cases() {
atf_add_test_case shlib_bump
atf_add_test_case shlib_bump_incomplete_revdep_in_trans
atf_add_test_case shlib_bump_revdep_in_trans
atf_add_test_case shlib_bump_revdep_diff
atf_add_test_case shlib_bump_versioned
}