Skip to content

Commit

Permalink
*
Browse files Browse the repository at this point in the history
  • Loading branch information
ofalvai committed Nov 30, 2024
1 parent 54c89ed commit e3c3535
Showing 1 changed file with 24 additions and 29 deletions.
53 changes: 24 additions & 29 deletions bitrise.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,12 @@ stages:
workflows:
run_lint:
steps:
- bundle::setup_repo: {}
- bundle::run_lint: { }

run_unit_tests_macos:
steps:
- bundle::setup_repo: {}
- bundle::setup_go_junit_report: { }
- bundle::run_unit_tests: { }
meta:
Expand All @@ -47,11 +49,13 @@ workflows:

run_unit_tests_linux:
steps:
- bundle::setup_repo: {}
- bundle::setup_go_junit_report: { }
- bundle::run_unit_tests: { }

run_integration_tests_macos:
steps:
- bundle::setup_repo: {}
- bundle::setup_go_junit_report: { }
- bundle::run_integration_tests: { }
meta:
Expand All @@ -61,11 +65,13 @@ workflows:

run_integration_tests_linux:
steps:
- bundle::setup_repo: {}
- bundle::setup_go_junit_report: { }
- bundle::run_integration_tests: { }

run_docker_integration_tests_linux:
steps:
- bundle::setup_repo: {}
- bundle::setup_go_junit_report: { }
- bundle::run_docker_integration_tests:
envs:
Expand All @@ -77,6 +83,7 @@ workflows:

test_binary_build_macos:
steps:
- bundle::setup_repo: {}
- bundle::setup_goreleaser: { }
- bundle::test_binary_build: { }
meta:
Expand All @@ -86,6 +93,7 @@ workflows:

test_binary_build_linux:
steps:
- bundle::setup_repo: {}
- bundle::setup_goreleaser: { }
- bundle::test_binary_build: { }

Expand Down Expand Up @@ -168,13 +176,6 @@ workflows:
step_bundles:
run_lint:
steps:
- git-clone@8:
inputs:
- fetch_tags: "yes"
- script:
title: Setup Go version
inputs:
- content: asdf install golang
- git::https://github.com/bitrise-steplib/steps-check.git:
inputs:
- workflow: lint
Expand All @@ -183,18 +184,13 @@ step_bundles:

run_unit_tests:
steps:
- git-clone@8:
inputs:
- fetch_tags: "yes"
- script@1:
title: Run unit tests
inputs:
- content: |-
#!/usr/bin/env bash
set -ex
asdf install golang # version defined in .tool-versions
# Here we save the original test results and deploy directories and later on we recreate them,
# because during the tests these directories are removed.
ORIG_BITRISE_TEST_RESULT_DIR="${BITRISE_TEST_RESULT_DIR}"
Expand Down Expand Up @@ -224,18 +220,13 @@ step_bundles:

run_integration_tests:
steps:
- git-clone@8:
inputs:
- fetch_tags: "yes"
- script@1:
title: Run integration tests
inputs:
- content: |-
#!/usr/bin/env bash
set -exo pipefail
asdf install golang # version defined in .tool-versions
# Here we save the original test results and deploy directories and later on we recreate them,
# because during the tests these directories are removed.
ORIG_BITRISE_TEST_RESULT_DIR="${BITRISE_TEST_RESULT_DIR}"
Expand Down Expand Up @@ -276,19 +267,13 @@ step_bundles:

run_docker_integration_tests:
steps:
- git-clone@8:
inputs:
- fetch_tags: "yes"
- script@1:
title: Run integration tests
inputs:
- content: |-
#!/usr/bin/env bash
set -exo pipefail
asdf plugin add golang || true # TODO: can be removed once workflow is migrated to Ubuntu 22
asdf install golang # version defined in .tool-versions
# Here we save the original test results and deploy directories and later on we recreate them,
# because during the tests these directories are removed.
ORIG_BITRISE_TEST_RESULT_DIR="${BITRISE_TEST_RESULT_DIR}"
Expand Down Expand Up @@ -324,9 +309,6 @@ step_bundles:

test_binary_build:
steps:
- git-clone@8:
inputs:
- fetch_tags: "yes"
- script@1:
title: Create snapshot binaries
deps:
Expand All @@ -340,6 +322,21 @@ step_bundles:
goreleaser release --snapshot --rm-dist
- deploy-to-bitrise-io@2: { }

setup_repo:
steps:
- git-clone@8:
inputs:
- fetch_tags: "yes"
- script:
title: Setup Go version
inputs:
- content: |-
#!/bin/bash
set -ex
asdf plugin add golang || true # TODO: can be removed once all workflows are migrated to Ubuntu 22
asdf install golang
setup_go_junit_report:
steps:
- script@1:
Expand All @@ -348,9 +345,8 @@ step_bundles:
- content: |-
#!/usr/bin/env bash
set -ex
asdf install golang # version defined in .tool-versions
go install github.com/jstemmer/go-junit-report/v2@latest
asdf reshim golang || true
asdf reshim golang
setup_goreleaser:
steps:
Expand All @@ -360,7 +356,6 @@ step_bundles:
#!/bin/bash
set -ex
asdf install golang # version defined in .tool-versions
if [ "$(uname)" = "Linux" ]; then
wget -O /tmp/goreleaser.deb https://github.com/goreleaser/goreleaser/releases/download/v1.19.2/goreleaser_1.19.2_amd64.deb
sudo dpkg -i /tmp/goreleaser.deb
Expand Down

0 comments on commit e3c3535

Please sign in to comment.