Skip to content

Modify the presubmit.yaml to include MacOS and Windows to validate tests and the verifier against #66

Modify the presubmit.yaml to include MacOS and Windows to validate tests and the verifier against

Modify the presubmit.yaml to include MacOS and Windows to validate tests and the verifier against #66

Workflow file for this run

name: presubmit
on:
pull_request:
push:
branches:
- main
workflow_dispatch:
permissions:
contents: read
jobs:
# Job 1: Build Plugin
build-plugin:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4 # Use the latest stable version of actions/checkout
- name: Set up JDK
uses: actions/setup-java@v4 # https://github.com/marketplace/actions/setup-java-jdk
with:
distribution: 'temurin' # Recommended distribution
java-version: '21' # Match version in build.gradle.kts
cache: 'gradle' # Cache Gradle dependencies
- name: Build Plugin Action
run: ./gradlew buildPlugin
working-directory: third_party
# Job 2: Unit Tests
unit-tests:
strategy:
matrix:
os: [ ubuntu-latest, macos-latest, windows-latest ]
runs-on: ${{ matrix.os }} # Use the OS from the matrix
steps:
- name: Checkout code
uses: actions/checkout@v4 # Use the latest stable version of actions/checkout
- name: Set up JDK
uses: actions/setup-java@v4 # https://github.com/marketplace/actions/setup-java-jdk
with:
distribution: 'temurin' # Recommended distribution
java-version: '21' # Match version in build.gradle.kts
cache: 'gradle' # Cache Gradle dependencies
- name: Unit Test Action
run: ./gradlew :test --tests "com.jetbrains.lang.dart.*"
working-directory: third_party
# Job 3: Verify Plugin
verify-plugin:
strategy:
matrix:
os: [ ubuntu-latest, macos-latest, windows-latest ]
runs-on: ${{ matrix.os }} # Use the OS from the matrix
steps:
- name: Checkout code
uses: actions/checkout@v4 # Use the latest stable version of actions/checkout
- name: Set up JDK
uses: actions/setup-java@v4 # https://github.com/marketplace/actions/setup-java-jdk
with:
distribution: 'temurin' # Recommended distribution
java-version: '21' # Match version in build.gradle.kts
cache: 'gradle' # Cache Gradle dependencies
- name: Verify Plugin Actions
run: |
./gradlew verifyPlugin
./gradlew verifyPluginProjectConfiguration
./gradlew verifyPluginSignature
./gradlew verifyPluginStructure
working-directory: third_party