🍽 Fork YunoHost — snapshot mangé par la machine à tsoins
Upstream: https://github.com/YunoHost/yunohost @ 3a5f8bac8301c450897b96cbd43a4c7d3ba750fb But (José) : transformer tout le code en bions + ploxions du xerboxion. La carte de digestion vit au labo : /yunohost-digest.json
This commit is contained in:
36
tests/test_helpers.v2.1.d/ynhtest_apt.sh
Normal file
36
tests/test_helpers.v2.1.d/ynhtest_apt.sh
Normal file
@@ -0,0 +1,36 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
ynhtest_apt_install_apt_deps_regular() {
|
||||
|
||||
cat << EOF > ../manifest.toml
|
||||
packaging_format = 2
|
||||
id = "${app:?}"
|
||||
version = "0.1~ynh2"
|
||||
EOF
|
||||
|
||||
if dpkg --list | grep -q "ii *$app-ynh-deps "; then
|
||||
apt remove "$app-ynh-deps" --assume-yes
|
||||
fi
|
||||
if dpkg --list | grep -q 'ii *nyancat '; then
|
||||
apt remove nyancat --assume-yes
|
||||
fi
|
||||
if dpkg --list | grep -q 'ii *sl '; then
|
||||
apt remove sl --assume-yes
|
||||
fi
|
||||
|
||||
! _ynh_apt_package_is_installed "$app-ynh-deps"
|
||||
! _ynh_apt_package_is_installed "nyancat"
|
||||
! _ynh_apt_package_is_installed "sl"
|
||||
|
||||
ynh_apt_install_dependencies "nyancat sl"
|
||||
|
||||
_ynh_apt_package_is_installed "$app-ynh-deps"
|
||||
_ynh_apt_package_is_installed "nyancat"
|
||||
_ynh_apt_package_is_installed "sl"
|
||||
|
||||
ynh_apt_remove_dependencies
|
||||
|
||||
! _ynh_apt_package_is_installed "$app-ynh-deps"
|
||||
! _ynh_apt_package_is_installed "nyancat"
|
||||
! _ynh_apt_package_is_installed "sl"
|
||||
}
|
||||
Reference in New Issue
Block a user