From 611b6853b25efa4ff8d0301db5afa586bb8a2801 Mon Sep 17 00:00:00 2001 From: Russtopia Date: Fri, 21 Aug 2020 19:47:37 -0700 Subject: [PATCH] Update 'bacillus/ci_pushbuild.sh' --- bacillus/ci_pushbuild.sh | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/bacillus/ci_pushbuild.sh b/bacillus/ci_pushbuild.sh index c49a483..8eba306 100755 --- a/bacillus/ci_pushbuild.sh +++ b/bacillus/ci_pushbuild.sh @@ -1,4 +1,6 @@ #!/bin/bash +# +## bacillus (https://gogs.blitter.com/Russtopia/bacillus) build/test CI script export GOPATH="${HOME}/go" export PATH=/usr/local/bin:/usr/bin:/usr/lib/ccache/bin:/bin:$GOPATH/bin @@ -22,15 +24,21 @@ echo "Building most recent push on branch $branch" git checkout "$branch" ls +############ stage "Build" +############ make all +############ stage "UnitTests" +############ go test -v . +############ stage "Test(Authtoken)" +############ echo "Clearing test user $USER ~/.xs_id file ..." -rm -f ~/.xs_id +mv ~/.xs_id ~/.xs_id.bak echo "Setting dummy authtoken in ~/.xs_id ..." echo "localhost:asdfasdfasdf" >~/.xs_id echo "Performing remote command on @localhost via authtoken login ..." @@ -42,8 +50,11 @@ else echo "client cmd performed OK." unset tokentest fi +mv ~/.xs_id.bak ~/.xs_id +############ stage "Test(S->C)" +############ echo "Testing secure copy from server -> client ..." tmpdir=$$ mkdir -p /tmp/$tmpdir @@ -63,17 +74,25 @@ else exit $stat fi +############ stage "Test(C->S)" +############ echo "TODO ..." +############ stage "Lint" +############ make lint +############ stage "Artifacts" +############ echo -n "Creating tarfile ..." tar -cz --exclude=.git --exclude=cptest -f ${BACILLUS_ARTFDIR}/xs.tgz . +############ stage "Cleanup" +############ rm -f ~/.xs_id echo