Skip to content

Commit

Permalink
Merge pull request #10 from ZLLentz/mnt_tst_2to3
Browse files Browse the repository at this point in the history
MNT/TST: Update to Python 3 and Add Tests
  • Loading branch information
ZLLentz authored Dec 11, 2024
2 parents a982b96 + 13dbb5a commit b35f91e
Show file tree
Hide file tree
Showing 33 changed files with 1,582 additions and 500 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Custom simplest pytest action
# Normally we should use pcds-ci-helpers, but that expects an installable package.
# In the future this package could be refactored to be installable,
# And then we'd switch this out for the standard ci suite
name: pytest

on:
push:
pull_request:
release:
types:
- created

jobs:
test:
name: "Python 3.9: (pip)"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-python@v5
with:
python-version: "3.9"
- name: pip
run: pip install pytest
- name: pytest
run: pytest -v
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
realpath
__pycache__
core.*
tests/common/*
tests/examples/*
tests/expected/*
34 changes: 34 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks

exclude: |
(?x)^(
tests/common/.*|
tests/examples/.*|
tests/expected/.*|
)$
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: no-commit-to-branch
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-ast
- id: check-case-conflict
- id: check-json
- id: check-merge-conflict
- id: check-symlinks
- id: check-xml
- id: check-yaml
- id: debug-statements

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.8.1
hooks:
# Run the linter.
- id: ruff
args: [ --fix ]
# Run the formatter.
- id: ruff-format
160 changes: 0 additions & 160 deletions NOTES

This file was deleted.

Loading

0 comments on commit b35f91e

Please sign in to comment.