Skip to content

Integrated example project for Mill into CI task #1

Integrated example project for Mill into CI task

Integrated example project for Mill into CI task #1

name: Mill plugin tests
on:
push:
paths:
- modules/openapi-generator-mill-plugin/**
pull_request:
paths:
- modules/openapi-generator-mill-plugin/**
jobs:
test:
name: Mill plugin tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- name: Set up JDK 11
uses: actions/setup-java@v5
with:
java-version: 11
distribution: 'temurin'
- name: Cache maven dependencies
uses: actions/cache@v5
env:
cache-name: cache-maven-repository
with:
path: |
~/.m2/repository
~/.gradle
!~/.gradle/caches/*/plugin-resolution/
!~/.m2/repository/org/openapitools/
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-test-mill-plugin-${{ env.cache-name }}-
${{ runner.os }}-test-mill-plugin-
- name: Run tests
env:
GRADLE_ENTERPRISE_ACCESS_KEY: ${{ secrets.GRADLE_ENTERPRISE_ACCESS_KEY }}
run: |
./mvnw clean install -DskipTests -Dmaven.javadoc.skip=true
(cd modules/openapi-generator-mill-plugin/example/ && ./mill __.compile)
(cd modules/openapi-generator-mill-plugin/example/ && ./mill openapi.validate)
(cd modules/openapi-generator-mill-plugin/example/ && ./mill validateOpenapiSpec $(pwd)/api/petstore-invalid.yaml)