bugfix: Use existing auto import functionality instead #16420
Workflow file for this run
This file contains hidden or 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: CI | |
| on: | |
| push: | |
| branches: | |
| - main | |
| pull_request: | |
| concurrency: | |
| group: ci-${{ github.ref }} | |
| cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
| jobs: | |
| unit: | |
| name: ${{ matrix.os }} jdk-${{ matrix.java }} unit tests ${{ matrix.shard }} / 2 | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [windows-latest, macOS-latest, ubuntu-latest] | |
| java: ["21"] | |
| shard: [1, 2] | |
| include: | |
| - os: ubuntu-latest | |
| java: "17" | |
| shard: 1 | |
| - os: ubuntu-latest | |
| java: "17" | |
| shard: 2 | |
| - os: ubuntu-latest | |
| java: "24" | |
| shard: 1 | |
| - os: ubuntu-latest | |
| java: "24" | |
| shard: 2 | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - uses: coursier/setup-action@v1 | |
| - uses: actions/setup-java@v5 | |
| with: | |
| distribution: 'temurin' | |
| java-version: ${{ matrix.java }} | |
| cache: 'sbt' | |
| - uses: sbt/setup-sbt@v1 | |
| - name: Run unit tests | |
| run: | | |
| bin/test.sh unit/test | |
| env: | |
| JAVA_VERSION: ${{ matrix.java }} | |
| TEST_SHARD: ${{ matrix.shard }} | |
| GOOGLE_APPLICATION_CREDENTIALS: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }} | |
| GOOGLE_APPLICATION_CREDENTIALS_JSON: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS_JSON }} | |
| shell: bash | |
| - name: Upload test reports | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: test-reports | |
| path: "**/.reports/**/*" | |
| if-no-files-found: ignore | |
| retention-days: 7 | |
| compression-level: 9 | |
| integration: | |
| name: ${{ matrix.name }} | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| type: | |
| [ | |
| gradle-mac, | |
| sbt, | |
| maven, | |
| gradle, | |
| scalacli, | |
| mill, | |
| bazel, | |
| feature, | |
| cross, | |
| scalafmt, | |
| scalafix, | |
| ] | |
| include: | |
| - type: gradle-mac | |
| command: bin/test.sh 'slow/testOnly -- tests.gradle.*' | |
| name: Gradle MacOS integration | |
| os: macOS-latest | |
| java: "17" | |
| - type: sbt | |
| command: | | |
| bin/test.sh +sbt-metals/publishLocal | |
| bin/test.sh 'slow/testOnly -- tests.sbt.*' | |
| name: Sbt integration | |
| os: ubuntu-latest | |
| java: "17" | |
| - type: sbt-metals jdk8 | |
| command: bin/test.sh sbt-metals/scripted | |
| name: Sbt-metals/scripted jdk11 | |
| os: ubuntu-latest | |
| java: "11" | |
| - type: sbt-metals Sbt 2 | |
| command: bin/test.sh '++3.x; sbt-metals/scripted' | |
| name: sbt-metals/scripted (Sbt 2) | |
| os: ubuntu-latest | |
| java: "21" | |
| - type: maven | |
| command: bin/test.sh 'slow/testOnly -- tests.maven.*' | |
| name: Maven integration | |
| os: ubuntu-latest | |
| java: "21" | |
| - type: gradle | |
| command: bin/test.sh 'slow/testOnly -- tests.gradle.*' | |
| name: Gradle integration | |
| os: ubuntu-latest | |
| java: "17" | |
| - type: mill | |
| command: bin/test.sh 'slow/testOnly -- tests.mill.*' | |
| name: Mill integration | |
| os: ubuntu-latest | |
| java: "21" | |
| - type: bazel | |
| command: bin/test.sh 'slow/testOnly -- tests.bazel.*' | |
| name: Bazel integration | |
| os: ubuntu-latest | |
| java: "21" | |
| - type: scalacli | |
| command: bin/test.sh 'slow/testOnly -- tests.scalacli.*' | |
| name: Scala CLI integration | |
| os: ubuntu-latest | |
| java: "21" | |
| - type: feature | |
| command: bin/test.sh 'slow/testOnly -- tests.feature.*' | |
| name: LSP integration tests | |
| os: ubuntu-latest | |
| java: "21" | |
| - type: cross | |
| command: sbt +cross/test | |
| name: Scala cross tests | |
| os: ubuntu-latest | |
| java: "17" | |
| - type: mtags-java | |
| command: sbt javapc/test | |
| name: Scala javapc tests | |
| os: ubuntu-latest | |
| java: "21" | |
| - type: cross-test-2-11 | |
| command: sbt cross-test-2-11 | |
| name: Scala 2.11 cross tests | |
| os: ubuntu-latest | |
| java: "21" | |
| - type: scalafix | |
| command: sbt scalafixCheck docs/docusaurusCreateSite | |
| name: Scalafix and docs | |
| os: ubuntu-latest | |
| java: "21" | |
| - type: scalafmt | |
| command: ./bin/scalafmt --test | |
| name: Formatting | |
| os: ubuntu-latest | |
| java: "21" | |
| - type: MiMa | |
| command: sbt interfaces/mimaReportBinaryIssues | |
| name: MiMa | |
| os: ubuntu-latest | |
| java: "21" | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - uses: actions/setup-java@v5 | |
| with: | |
| distribution: 'temurin' | |
| java-version: ${{ matrix.java }} | |
| cache: 'sbt' | |
| - uses: sbt/setup-sbt@v1 | |
| with: | |
| sbt-runner-version: 1.10.3 | |
| - name: ${{ matrix.command }} | |
| run: | | |
| ${{ matrix.command }} | |
| env: | |
| METALS_TEST: true | |
| GOOGLE_APPLICATION_CREDENTIALS: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS }} | |
| GOOGLE_APPLICATION_CREDENTIALS_JSON: ${{ secrets.GOOGLE_APPLICATION_CREDENTIALS_JSON }} | |
| - name: Upload test reports | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: test-reports | |
| path: "**/.reports/**/*" | |
| if-no-files-found: ignore | |
| retention-days: 7 | |
| compression-level: 9 | |
| - name: "test download dependencies" | |
| run: sbt downloadDependencies | |
| if: matrix.type == 'cross' |