bstinson / centos / t_functional

Forked from centos/t_functional 4 years ago
Clone

Blame tests/z_cr_test/cr-test.sh

4ebcb5
#!/bin/bash
4ebcb5
# determining which packages we need to install from Base+Updates before trying the update against CR
4ebcb5
4ebcb5
# generate local cache
58ff4a
/tmp/t_functional/tests/0_common/00_qa_repo_config.sh
be772a
mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.disabled
4ebcb5
yum --enablerepo=qa-cr list >/dev/null 2>&1 
38498c
sqlite3 $(find /var/cache/yum/$(t_GetArch)/$(t_DistCheck)/qa-cr/ -iname '*.sqlite*') 'select name from packages;' > /tmp/packages.list
4ebcb5
t_Log "Installing needed packages from Base"
4ebcb5
yum install -y -d0 $(cat /tmp/packages.list) 1>/dev/null
4ebcb5
t_CheckExitStatus $?
be772a
# remove centos-release-cr from the packages list
be772a
yum remove -y -d0 centos-release-cr
4ebcb5
4ebcb5
t_Log "Updating packages with the CR repo"
4ebcb5
t_InstallPackage yum-presto
4ebcb5
yum install --enablerepo=qa-cr -y -d0 $(cat /tmp/packages.list) 
4ebcb5
t_CheckExitStatus $?
be772a
yum remove -y -d0 centos-release-cr
be772a
mv /etc/yum.repos.d/CentOS-Base.repo.disabled /etc/yum.repos.d/CentOS-Base.repo
be772a
mv /etc/yum.repos.d/CentOS-QA.repo /etc/yum.repos.d/CentOS-QA.repo.disabled