Allow providing release and snapshot repositories #300
Workflow file for this run
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
name: Test | |
on: | |
push: | |
# Triggers the workflow on labeled PRs only. | |
pull_request_target: | |
types: [ labeled ] | |
jobs: | |
test: | |
if: github.event_name == 'push' || (github.event_name == 'pull_request_target' && contains(github.event.pull_request.labels.*.name, 'safe to test')) | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ ubuntu-latest, windows-latest, macOS-latest ] | |
java-version: [ "8", "11" ] | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
ref: ${{ github.event.pull_request.head.sha }} | |
# Install required tools | |
- name: Set up Java | |
uses: actions/setup-java@v3 | |
with: | |
distribution: "temurin" | |
java-version: ${{ matrix.java-version }} | |
- name: Setup Artifactory | |
env: | |
RTLIC: ${{ secrets.RTLIC }} | |
GOPROXY: direct | |
run: | | |
go install github.com/jfrog/jfrog-testing-infra/local-rt-setup@latest | |
~/go/bin/local-rt-setup | |
# Run tests | |
- name: Tests on macOS, Linux | |
run: ./gradlew clean validatePlugins check | |
if: runner.os != 'Windows' | |
- name: Tests on Windows | |
run: ./gradlew.bat clean check | |
if: runner.os == 'Windows' | |
# Stop Gradle daemon | |
- name: Stop Gradle | |
run: ./gradlew --stop |