Created
October 16, 2018 19:36
-
-
Save koral--/dad14633121bbf14d3fb384b2b79a79e to your computer and use it in GitHub Desktop.
Bitrise step test workflow
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
test: | |
steps: | |
- go-list: {} | |
- golint: {} | |
- errcheck: {} | |
- script: | |
inputs: | |
- content: |- | |
#!/usr/bin/env bash | |
go vet | |
- go-test: {} | |
- change-workdir: | |
title: Switch working dir to test / _tmp dir | |
description: |- | |
To prevent step testing issues, like referencing relative | |
files with just './some-file' in the step's code, which would | |
work for testing the step from this directory directly | |
but would break if the step is included in another `bitrise.yml`. | |
run_if: "true" | |
inputs: | |
- path: ./_tmp | |
- is_create_path: true | |
- path::./: | |
title: Step Test | |
- script: | |
title: Verify environment | |
inputs: | |
- content: |- | |
#!/usr/bin/env bash | |
set -e | |
if [[ -z "$CHUCK_NORRIS_JOKE" ]]; then | |
echo "CHUCK_NORRIS_JOKE environment variable is empty or not set" | |
exit 1 | |
fi | |
echo "This output was generated by the Step (CHUCK_NORRIS_JOKE): $CHUCK_NORRIS_JOKE" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment