Skip to content

Commit 44c33e3

Browse files
committed
Initial commit
1 parent b9bddea commit 44c33e3

3 files changed

Lines changed: 126 additions & 0 deletions

File tree

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Code coverage
2+
on: [push, workflow_dispatch]
3+
jobs:
4+
run:
5+
runs-on: ubuntu-latest
6+
env:
7+
OS: ubuntu-latest
8+
PYTHON: '3.11'
9+
steps:
10+
- uses: actions/checkout@v4
11+
12+
- name: Install uv and set the python version
13+
uses: astral-sh/setup-uv@v5
14+
with:
15+
python-version: '3.13'
16+
17+
- name: Install the project
18+
run: uv sync --locked --all-extras --dev
19+
20+
- name: Generate coverage report
21+
run: uv run pytest -n logical --cov=fractured_json --cov-report=xml
22+
23+
- name: Upload coverage to Codecov
24+
uses: codecov/codecov-action@v3
25+
with:
26+
token: ${{ secrets.CODECOV_TOKEN }}
27+
directory: ./coverage/reports/
28+
env_vars: OS,PYTHON
29+
fail_ci_if_error: true
30+
files: ./coverage.xml
31+
flags: unittests
32+
name: codecov-umbrella
33+
verbose: true

.github/workflows/codeql.yml

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: "CodeQL"
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
# The branches below must be a subset of the branches above
8+
branches: [ "main" ]
9+
schedule:
10+
- cron: '21 18 * * 0'
11+
workflow_dispatch:
12+
13+
jobs:
14+
analyze:
15+
name: Analyze
16+
runs-on: ubuntu-latest
17+
permissions:
18+
actions: read
19+
contents: read
20+
security-events: write
21+
22+
strategy:
23+
fail-fast: false
24+
matrix:
25+
language: [ 'python' ]
26+
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
27+
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
28+
29+
steps:
30+
- name: Checkout repository
31+
uses: actions/checkout@v3
32+
33+
# Initializes the CodeQL tools for scanning.
34+
- name: Initialize CodeQL
35+
uses: github/codeql-action/init@v2
36+
with:
37+
languages: ${{ matrix.language }}
38+
# If you wish to specify custom queries, you can do so here or in a config file.
39+
# By default, queries listed here will override any specified in a config file.
40+
# Prefix the list here with "+" to use these queries and those in the config file.
41+
42+
# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
43+
# queries: security-extended,security-and-quality
44+
45+
46+
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
47+
# If this step fails, then you should remove it and run the build manually (see below)
48+
- name: Autobuild
49+
uses: github/codeql-action/autobuild@v2
50+
51+
# ℹ️ Command-line programs to run using the OS shell.
52+
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
53+
54+
# If the Autobuild fails above, remove it and uncomment the following three lines.
55+
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
56+
57+
# - run: |
58+
# echo "Run, Build Application using script"
59+
# ./location_of_script_within_repo/buildscript.sh
60+
61+
- name: Perform CodeQL Analysis
62+
uses: github/codeql-action/analyze@v2
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: All tests
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
workflow_dispatch:
9+
10+
jobs:
11+
build:
12+
13+
runs-on: ubuntu-latest
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
python-version: ["3.11", "3.12", "3.13"]
18+
19+
steps:
20+
- uses: actions/checkout@v4
21+
22+
- name: Install uv and set the python version
23+
uses: astral-sh/setup-uv@v5
24+
with:
25+
python-version: ${{ matrix.python-version }}
26+
27+
- name: Install the project
28+
run: uv sync --locked --all-extras --dev
29+
30+
- name: Run tests
31+
run: uv run pytest -n logical

0 commit comments

Comments
 (0)