Skip to content

Update gradle-tests.yml #52

Update gradle-tests.yml

Update gradle-tests.yml #52

Workflow file for this run

# This workflow will build a package using Gradle and then publish it to GitHub packages when a release is created
# For more information see: https://github.com/actions/setup-java/blob/main/docs/advanced-usage.md#Publishing-using-gradle
name: Gradle Tests
on:
push:
branches:
- master
- develop
pull_request:
branches:
- master
- develop
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
build:
environment: Test
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
distribution: 'corretto' # See 'Supported distributions' for available options
java-version: '17'
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml
settings-path: ${{ github.workspace }} # location for the settings.xml file
- name: Build with Gradle
run: gradle test -Doauth2AccessToken=${{ secrets.OAUTH2ACCESSTOKEN }} -DconsumerSecret=${{ secrets.CONSUMERSECRET }} -DaccessToken=${{ secrets.ACCESSTOKEN }} -DconsumerKey=${{ secrets.CONSUMERKEY }} -DaccessTokenSecret=${{ secrets.ACCESSTOKENSECRET }}
env:
oauth2AccessToken: ${{ secrets.OAUTH2ACCESSTOKEN }}
consumerKey: ${{ secrets.CONSUMERKEY }}
consumerSecret: ${{ secrets.CONSUMERSECRET }}
accessToken: ${{ secrets.ACCESSTOKEN }}
accessTokenSecret: ${{ secrets.ACCESSTOKENSECRET }}