Skip to content

Commit

Permalink
ci: add example build to ci
Browse files Browse the repository at this point in the history
  • Loading branch information
malandis committed Sep 16, 2024
1 parent a0e1ec6 commit 2750240
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/on-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,3 +50,37 @@ jobs:

- name: Run tests vs redis
run: make test-redis

build-examples:
runs-on: ubuntu-latest
env:
MOMENTO_API_KEY: ${{ secrets.ALPHA_TEST_AUTH_TOKEN }}

steps:
- name: Checkout project
uses: actions/checkout@v3

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: 17
distribution: 'corretto'

- name: Build examples
uses: gradle/gradle-build-action@v2
id: validation
continue-on-error: true
with:
build-root-directory: ./examples
arguments: clean build

- name: Send CI failure mail
if: ${{ steps.validation.outcome == 'failure' }}
uses: momentohq/standards-and-practices/github-actions/error-email-action@gh-actions-v1
with:
username: ${{secrets.MOMENTO_ROBOT_GMAIL_USERNAME}}
password: ${{secrets.MOMENTO_ROBOT_GMAIL_PASSWORD}}

- name: Flag Job Failure
if: ${{ steps.validation.outcome == 'failure' }}
run: exit 1

0 comments on commit 2750240

Please sign in to comment.