mirror of
https://github.com/actions/runner-images.git
synced 2025-12-14 13:17:54 +00:00
[Ubuntu] Migrate PowerShell and Docker tests to Pester (#2317)
* PowerShell and Docker Pester tests * no pester module * import pester * invoke docker with sudo * remove native test * add fix for az 1.0.0 module * revert powershellget installation * revert flag Force * add $ProgressPreference = "SilentlyContinue"
This commit is contained in:
committed by
GitHub
parent
ec4b0fa89c
commit
ac87b63b13
@@ -6,6 +6,7 @@
|
||||
|
||||
# Source the helpers for use with the script
|
||||
source $HELPER_SCRIPTS/install.sh
|
||||
source $HELPER_SCRIPTS/invoke-tests.sh
|
||||
|
||||
# Check to see if docker is already installed
|
||||
docker_package=moby
|
||||
@@ -24,21 +25,9 @@ fi
|
||||
systemctl is-active --quiet docker.service || systemctl start docker.service
|
||||
systemctl is-enabled --quiet docker.service || systemctl enable docker.service
|
||||
|
||||
# Run tests to determine that the software installed as expected
|
||||
echo "Testing to make sure that script performed as expected, and basic scenarios work"
|
||||
echo "Checking the docker-moby and moby-buildx"
|
||||
if ! command -v docker; then
|
||||
echo "docker was not installed"
|
||||
exit 1
|
||||
elif ! [[ $(docker buildx) ]]; then
|
||||
echo "Docker-Buildx was not installed"
|
||||
exit 1
|
||||
else
|
||||
echo "Docker-moby and Docker-buildx checking the successfull"
|
||||
# Docker daemon takes time to come up after installing
|
||||
sleep 10
|
||||
docker info
|
||||
fi
|
||||
# Docker daemon takes time to come up after installing
|
||||
sleep 10
|
||||
docker info
|
||||
|
||||
# Pull images
|
||||
toolset="$INSTALLER_SCRIPT_FOLDER/toolset.json"
|
||||
@@ -46,3 +35,5 @@ images=$(jq -r '.docker.images[]' $toolset)
|
||||
for image in $images; do
|
||||
docker pull "$image"
|
||||
done
|
||||
|
||||
invoke_tests "Tools" "Docker"
|
||||
Reference in New Issue
Block a user