testdata: simplify goversion test (#232)

As per the TODO, just set up the files in the right places.
pull/234/head
Daniel Martí 3 years ago committed by GitHub
parent af517a20f8
commit a499a6bcd7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1,9 +1,5 @@
# TODO: Place file direct to .bin directory
mkdir .bin
cp go.sh .bin/go
cp go.bat .bin/go.bat
chmod 777 .bin/go
env PATH=.bin${:}${PATH}
env PATH=${WORK}/.bin${:}${PATH}
# Check incorrect go install
env GO_VERSION=''
@ -45,11 +41,11 @@ env GO_VERSION='go version go1.15.2 windows/amd64'
-- main.go --
package main
-- go.sh --
-- .bin/go --
#!/bin/sh
[ -z "$GO_VERSION" ] && exit 1 || echo "$GO_VERSION"
-- go.bat --
-- .bin/go.bat --
@echo off
IF DEFINED GO_VERSION (echo %GO_VERSION%) ELSE (exit 1)

Loading…
Cancel
Save