Add a github action that generates a couple of clients using openapi generator (#60)

Adds a quick layer of validation at CI level.
This commit is contained in:
Justin Auger 2023-06-24 05:35:42 +01:00 committed by GitHub
parent b792362027
commit 0d7bb3cca9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

26
.github/workflows/validate.yml vendored Normal file
View File

@ -0,0 +1,26 @@
name: Validate OpenAPI Spec
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
generate:
runs-on: ubuntu-latest
name: Generate Clients
steps:
- uses: actions/checkout@v2
- name: Typescript Axios
uses: openapi-generators/openapitools-generator-action@v1
with:
generator: typescript-axios
openapi-file: ./reference/SpaceTraders.json
- name: Dart
uses: openapi-generators/openapitools-generator-action@v1
with:
generator: dart
openapi-file: ./reference/SpaceTraders.json