v/integration/install_specific_version
Marc Cataford 096c7b37ef
ci: add basic integration test, pipeline step (#7)
* ci: add basic integration test, pipeline step

fix: pull_request trigger

fix: env declaration format

* ci: hoist env def to step instead of individual run

* ci: trigger on main push
2023-11-05 11:47:24 -05:00

21 lines
444 B
Bash

#!/bin/bash
# Scenario: User installs a specific version of python.
echo "Scenario: User installs a specific version of Python"
go build .
TARGET_VERSION="3.10.0"
V_ROOT=/tmp/v ./v init
V_ROOT=/tmp/v ./v install $TARGET_VERSION --no-cache
INSTALLED_VERSIONS=$(V_ROOT=/tmp/v ./v ls)
if [ -z "$(echo $INSTALLED_VERSIONS | grep $TARGET_VERSION)" ]; then
echo "FAIL: Could not find target version."
exit 1
else
echo "SUCCESS"
fi