35 lines
844 B
Bash
35 lines
844 B
Bash
#!/usr/bin/env atf-sh
|
|
#
|
|
|
|
atf_test_case cyclic_dep_vpkg
|
|
|
|
cyclic_dep_vpkg_head() {
|
|
atf_set "descr" "Tests for cyclic deps: pkg depends on a cyclic vpkg"
|
|
}
|
|
|
|
cyclic_dep_vpkg_body() {
|
|
mkdir some_repo
|
|
mkdir -p pkg_{A,B,C,D}/usr/bin
|
|
cd some_repo
|
|
xbps-create -A noarch -n A-1.0_1 -s "A pkg" --provides "libGL-7.11_1" --dependencies "libGL>=7.11" ../pkg_A
|
|
atf_check_equal $? 0
|
|
xbps-create -A noarch -n B-1.0_1 -s "B pkg" --dependencies "libGL>=7.11" ../pkg_B
|
|
atf_check_equal $? 0
|
|
xbps-create -A noarch -n C-1.0_1 -s "C pkg" --dependencies "B>=0" ../pkg_C
|
|
atf_check_equal $? 0
|
|
|
|
xbps-rindex -d -a $PWD/*.xbps
|
|
atf_check_equal $? 0
|
|
cd ..
|
|
|
|
xbps-install -r root --repository=$PWD/some_repo -dy C
|
|
atf_check_equal $? 0
|
|
|
|
xbps-query -r root --fulldeptree -x C
|
|
atf_check_equal $? 0
|
|
}
|
|
|
|
atf_init_test_cases() {
|
|
atf_add_test_case cyclic_dep_vpkg
|
|
}
|