Add tests for python code (#2759)

* add tests for python code

* ruff format
This commit is contained in:
Hare Sudhan
2024-04-27 12:38:14 -05:00
committed by GitHub
parent 58496ee330
commit 82fc8d41cc
22 changed files with 612 additions and 156 deletions
+29
View File
@@ -0,0 +1,29 @@
name: validate-python-file-changes
on:
pull_request:
branches:
- master
paths:
- "atomic_red_team/**/*.py"
jobs:
validate-python-file-changes:
runs-on: ubuntu-latest
steps:
- name: checkout repo
uses: actions/checkout@v4
- name: Install poetry
run: pipx install poetry
- name: setup python3.11
uses: actions/setup-python@v5
id: setup-python
with:
python-version: "3.11.2"
cache: "poetry"
- name: Install dependencies
run: poetry install --no-interaction
- name: Run pytest
run: poetry run pytest atomic_red_team/tests