Skip to content

Commit e19545f

Browse files
authored
SWI-1779 Update test workflow to run on feature branch (#81)
* Update test workflow to run on feature branch * add env vars
1 parent f117d72 commit e19545f

File tree

1 file changed

+52
-2
lines changed

1 file changed

+52
-2
lines changed

.github/workflows/test.yml

Lines changed: 52 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ concurrency:
1111
cancel-in-progress: true
1212

1313
jobs:
14-
test:
15-
name: Test
14+
test_production:
15+
name: Test Production
1616
runs-on: ${{ matrix.os }}
1717
strategy:
1818
matrix:
@@ -49,3 +49,53 @@ jobs:
4949
job-status: ${{ job.status }}
5050
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
5151
slack-channel: ${{ secrets.SLACK_CHANNEL }}
52+
53+
test_feature:
54+
name: Test Feature Branch
55+
needs: test_production
56+
runs-on: ${{ matrix.os }}
57+
strategy:
58+
matrix:
59+
os: [windows-2022, windows-2019, ubuntu-20.04, ubuntu-22.04]
60+
ruby-version: [2.7, 3.0, 3.1, 3.2]
61+
steps:
62+
- name: Checkout
63+
uses: actions/checkout@v3
64+
with:
65+
ref: 'feature/openapi-generator-sdk'
66+
67+
- name: Set up Ruby
68+
uses: ruby/setup-ruby@v1
69+
with:
70+
ruby-version: ${{ matrix.ruby-version }}
71+
72+
- name: Install Packages
73+
run: bundle install
74+
75+
- name: Test
76+
env:
77+
BW_ACCOUNT_ID: ${{ secrets.BW_ACCOUNT_ID }}
78+
BW_USERNAME: ${{ secrets.BW_USERNAME }}
79+
BW_PASSWORD: ${{ secrets.BW_PASSWORD }}
80+
BW_USERNAME_FORBIDDEN: ${{ secrets.BW_USERNAME_FORBIDDEN }}
81+
BW_PASSWORD_FORBIDDEN: ${{ secrets.BW_PASSWORD_FORBIDDEN }}
82+
BW_VOICE_APPLICATION_ID: ${{ secrets.BW_VOICE_APPLICATION_ID }}
83+
BW_MESSAGING_APPLICATION_ID: ${{ secrets.BW_MESSAGING_APPLICATION_ID }}
84+
BW_NUMBER: ${{ secrets.BW_NUMBER }}
85+
USER_NUMBER: ${{ secrets.USER_NUMBER }}
86+
BASE_CALLBACK_URL: ${{ secrets.BASE_CALLBACK_URL }}
87+
RUBY_VERSION: ${{ matrix.ruby-version }}
88+
OPERATING_SYSTEM: ${{ matrix.os }}
89+
MANTECA_ACTIVE_NUMBER: ${{ secrets.MANTECA_ACTIVE_NUMBER }}
90+
MANTECA_IDLE_NUMBER: ${{ secrets.MANTECA_IDLE_NUMBER }}
91+
MANTECA_BASE_URL: ${{ secrets.MANTECA_BASE_URL }}
92+
MANTECA_APPLICATION_ID: ${{ secrets.MANTECA_APPLICATION_ID }}
93+
run: rake
94+
95+
- name: Notify Slack of Failures
96+
uses: Bandwidth/[email protected]
97+
if: failure() && !github.event.pull_request.draft
98+
with:
99+
job-status: ${{ job.status }}
100+
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }}
101+
slack-channel: ${{ secrets.SLACK_CHANNEL }}

0 commit comments

Comments
 (0)