Skip to content

Commit

Permalink
ci: build DSL-langium component
Browse files Browse the repository at this point in the history
  • Loading branch information
lars-reimann committed Apr 7, 2023
1 parent b3ba979 commit dd258de
Show file tree
Hide file tree
Showing 6 changed files with 725 additions and 5 deletions.
40 changes: 38 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Main
on:
push:
branches: [main]
branches: [ main ]

jobs:
# Build and test DSL component
Expand All @@ -12,7 +12,7 @@ jobs:
working-directory: ./DSL
strategy:
matrix:
java-version: [17]
java-version: [ 17 ]

steps:
- name: Checkout repository
Expand Down Expand Up @@ -54,3 +54,39 @@ jobs:
coverage: ${{ matrix.python-version == '3.10' }}
secrets:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

# Build and test the DSL port to Langium
build-dsl-langium:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./DSL-langium

strategy:
matrix:
node-version: [ 18.x ]

steps:
- name: Checkout source
uses: actions/checkout@v3

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: npm
cache-dependency-path: DSL-langium/package-lock.json

- name: Install dependencies
run: npm ci

- name: Test with Vitest
run: npm run test-with-coverage

- name: Upload coverage to Codecov
if: ${{ github.actor != 'dependabot[bot]' }}
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
directory: DSL-langium/coverage
files: clover.xml
36 changes: 36 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,39 @@ jobs:
coverage: ${{ matrix.python-version == '3.10' }}
secrets:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

# Build and test the DSL port to Langium
build-dsl-langium:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./DSL-langium

strategy:
matrix:
node-version: [ 18.x ]

steps:
- name: Checkout source
uses: actions/checkout@v3

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: npm
cache-dependency-path: DSL-langium/package-lock.json

- name: Install dependencies
run: npm ci

- name: Test with Vitest
run: npm run test-with-coverage

- name: Upload coverage to Codecov
if: ${{ github.actor != 'dependabot[bot]' }}
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
directory: DSL-langium/coverage
files: clover.xml
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@
/DSL/**/bin/
/DSL-langium/**/generated/
build/
coverage/
dist/
dist-ssr/
out/

# Gradle
Expand Down
Loading

0 comments on commit dd258de

Please sign in to comment.