Skip to content

Commit

Permalink
ci: add TiCS analysis
Browse files Browse the repository at this point in the history
  • Loading branch information
jedel1043 authored and NucciTheBoss committed Oct 11, 2024
1 parent 00d0239 commit 850803a
Show file tree
Hide file tree
Showing 2 changed files with 44 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/nightly-TICS.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Nightly TICS scan

on:
schedule:
- cron: '01 07 * * *' # Every day at 07:01 UTC
workflow_dispatch:

permissions:
contents: read

jobs:
TICS:
runs-on: ubuntu-24.04
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Install requirements
run: |
sudo apt update -y
sudo apt install python3-venv -y
- name: Create and activate virtual environment
run: |
python3 -m venv .venv
. .venv/bin/activate
pip install tox pylint flake8 pytest
echo PATH=$PATH >> $GITHUB_ENV
- name: Run coverage tests
run: |
tox -e unit
- name: TICS GitHub Action
uses: tiobe/tics-github-action@v3
with:
mode: qserver
project: slurmutils
viewerUrl: https://canonical.tiobe.com/tiobeweb/TICS/api/cfg?name=default
branchdir: ${{ env.GITHUB_WORKSPACE }}
ticsAuthToken: ${{ secrets.TICS_AUTH_TOKEN }}
installTics: true
calc: ALL
1 change: 1 addition & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ commands =
--source={[vars]src_path} \
-m pytest -v --tb native -s {posargs} {[vars]tst_path}/unit
coverage report
coverage xml -o cover/coverage.xml

[testenv:publish]
description = Publish slurmutils to PyPI using poetry.
Expand Down

0 comments on commit 850803a

Please sign in to comment.