-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
56 additions
and
12 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,12 @@ | ||
on: [push, pull_request] | ||
name: luacheck | ||
|
||
on: [push, pull_request] | ||
|
||
jobs: | ||
lint: | ||
luacheck: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@master | ||
- name: lint | ||
uses: Roang-zero1/factorio-mod-luacheck@master | ||
with: | ||
luacheckrc_url: "" | ||
- name: Checkout | ||
uses: actions/checkout@master | ||
- name: Luacheck | ||
uses: lunarmodules/luacheck@master |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,56 @@ | ||
|
||
name: mineunit | ||
|
||
on: [push, pull_request] | ||
|
||
jobs: | ||
build: | ||
mineunit: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: mt-mods/mineunit-actions@badger | ||
|
||
- id: mineunit | ||
uses: mt-mods/mineunit-actions@master | ||
with: | ||
badge-label: Test coverage | ||
|
||
- uses: RubbaBoy/[email protected] | ||
if: success() && github.event_name == 'push' && github.ref == 'refs/heads/master' | ||
with: | ||
NAME: "${{ steps.mineunit.outputs.badge-name }}" | ||
LABEL: "${{ steps.mineunit.outputs.badge-label }}" | ||
STATUS: "${{ steps.mineunit.outputs.badge-status }}" | ||
COLOR: "${{ steps.mineunit.outputs.badge-color }}" | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- uses: KeisukeYamashita/create-comment@v1 | ||
if: success() && github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository | ||
with: | ||
check-only-first-line: true | ||
comment: | | ||
<details><summary><i>Click for detailed source code test coverage report</i></summary> | ||
### Mineunit test coverage is ${{ steps.mineunit.outputs.coverage-total }} in ${{ steps.mineunit.outputs.coverage-files }} files: | ||
``` | ||
File Hits Missed Coverage | ||
-------------------------------------------------------------- | ||
${{ steps.mineunit.outputs.mineunit-report }} | ||
``` | ||
### Mineunit test logs: | ||
``` | ||
${{ steps.mineunit.outputs.mineunit-stdout }} | ||
``` | ||
</details> | ||
- uses: KeisukeYamashita/create-comment@v1 | ||
if: failure() && github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository | ||
with: | ||
badge-secret: ${{ secrets.MineunitBadgesAPIKey }} | ||
check-only-first-line: true | ||
comment: | | ||
<details><summary><i>Mineunit tests failed, click for details</i></summary> | ||
### Mineunit test logs: | ||
``` | ||
${{ steps.mineunit.outputs.mineunit-stdout }} | ||
``` | ||
</details> |
This file contains 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