-
Notifications
You must be signed in to change notification settings - Fork 0
70 lines (59 loc) · 1.97 KB
/
check.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
---
name: check
# Controls when the workflow will run
# yamllint disable-line rule:truthy
on:
# Triggers the workflow on push or pull request events
# but only for the "main" and "develop" branch
push:
branches: [main, develop]
pull_request:
branches: [main, develop]
# Triggers the workflow on 3am every day
schedule:
- cron: '0 3 * * *'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
check:
runs-on: ubuntu-latest
concurrency: testing_environment
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Install Task
uses: arduino/setup-task@v2
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Set up python
id: setup-python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install and configure poetry
uses: snok/install-poetry@v1
with:
virtualenvs-create: true
virtualenvs-in-project: true
installer-parallel: true
- name: install copier
run: |
python3 -m pip install --user copier>=8.3.0
- name: create plugin with default answers and run check
env:
CMEM_BASE_URI: ${{ secrets.CMEM_BASE_URI }}
OAUTH_CLIENT_SECRET: ${{ secrets.OAUTH_CLIENT_SECRET }}
run: |
poetry self add "poetry-dynamic-versioning[plugin]"
task check
- name: Publish Test Report in Action
uses: mikepenz/action-junit-report@v4
if: always() # always run even if the previous step fails
with:
report_paths: cmem-plugin-awesome/dist/junit-*.xml
- name: Publish Test and Coverage Report as PR comment
uses: xportation/junit-coverage-report@main
if: github.event_name == 'pull_request'
with:
junit-path: cmem-plugin-awesome/dist/junit-pytest.xml
coverage-path: cmem-plugin-awesome/dist/coverage.xml