-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Issue #19: first cut adding .stone tests to github ci
- Loading branch information
1 parent
99fdf41
commit 0f6f879
Showing
8 changed files
with
105 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
pull_request: | ||
schedule: | ||
- cron: "15 2 21 * *" #run job on the 21st day of every month on the 15th minute of the 2nd hour | ||
|
||
|
||
jobs: | ||
build: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ ubuntu-18.04, macos-10.15 ] | ||
gsvers: [ 3.6.1 ] | ||
runs-on: ${{ matrix.os }} | ||
env: | ||
GS_VERS: ${{ matrix.gsvers }} | ||
PLATFORM: ${{ matrix.os }} | ||
steps: | ||
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | ||
- uses: actions/checkout@v2 | ||
|
||
# download the $GS_VERS product tree | ||
- name: setup | ||
run: | | ||
# set -x | ||
curl -L "https://github.com/kward/shunit2/archive/refs/tags/v2.1.8.tar.gz" | tar zx -C ${GITHUB_WORKSPACE}/shunit_tests | ||
pushd ${GITHUB_WORKSPACE}/tests/products | ||
${GITHUB_WORKSPACE}/dev/downloadGemStone.sh ${GS_VERS} | ||
echo "GEMSTONE=$GEMSTONE" | ||
popd | ||
. ${GITHUB_WORKSPACE}/dev/defPath.env | ||
- name: test | ||
run: | | ||
shunit_tests/testExamples.stone | ||
slack-workflow-status: | ||
if: always() | ||
name: Post Workflow Status To Slack | ||
needs: | ||
- build | ||
runs-on: ubuntu-18.04 | ||
steps: | ||
- name: Slack Workflow Notification | ||
uses: Gamesight/slack-workflow-status@master | ||
with: | ||
repo_token: ${{secrets.GITHUB_TOKEN}} | ||
slack_webhook_url: ${{secrets.SLACK_DALEHENRICH}} | ||
name: 'action run' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
#! /usr/bin/env bash | ||
vers="$1" | ||
${GITHUB_WORKSPACE}/dev/downloadGemStone.sh $vers | ||
if [ "$PLATFORM" = "macos-10.15" ] ; then | ||
ln -s GemStone64Bit${vers}-i386.Darwin product | ||
else | ||
ln -s GemStone64Bit${vers}-x86_64.Linux product | ||
fi`` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
#! /usr/bin/env bash | ||
|
||
. ${GITHUB_WORKSPACE}/dev/defPath.env | ||
|
||
PATH=${GITHUB_WORKSPACE}/examples/simple:$PATH | ||
|
||
test_errorWithHelp_solo() { | ||
# run without error | ||
errorWithHelp.stone -h | ||
errorWithHelp.stone --help | ||
} | ||
|
||
test_simplest_solo() { | ||
# run without error | ||
seven=`simplest.stone` | ||
assertEquals "wrong answer" '7' "${seven}" | ||
simplest.stone -h | ||
simplest.stone --help | ||
simplest.stone -D | ||
simplest.stone --debug | ||
} | ||
|
||
test_simpleArgs_1_stone() { | ||
# run without error | ||
seven=`simpleArgs.stone --addend=4` | ||
assertEquals "wrong answer" '7' "${seven}" | ||
} | ||
|
||
test_simpleArgs_2_stone() { | ||
# run without error | ||
seven=`simpleArgs.stone -a 4` | ||
assertEquals "wrong answer" '7' "${seven}" | ||
} | ||
|
||
. shunit_tests/shunit2-2.1.8/shunit2_test_helpers | ||
. shunit_tests/shunit2-2.1.8/shunit2 | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
* | ||
!README.md | ||
!.gitignore |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Primarily used for testing, but a convenient place to stash your gemstone product trees if you are not using GsDevKit_home. |