Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix autograder issues #3

Merged
merged 2 commits into from
May 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/classroom.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ jobs:
uses: classroom-resources/autograding-command-grader@v1
with:
test-name: test code formatting
setup-command: ''
command: python -m pytest
setup-command: 'pip install -r requirements.txt'
command: python -m pytest -m "not skipautograding"
timeout: 10
- name: Autograding Reporter
uses: classroom-resources/autograding-grading-reporter@v1
Expand Down
3 changes: 3 additions & 0 deletions pytest.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[pytest]
markers =
skipautograding: disable tests for autograding since environment is not consistent
3 changes: 2 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
pytest
black
flake8
flake8
flake8-nb
2 changes: 2 additions & 0 deletions tests/test_linter_formatter.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import os
import re
import subprocess
import pytest
from pathlib import Path


Expand All @@ -23,6 +24,7 @@ def test_flake8():
print("No stylistic errors found!")
assert failure == 0

@pytest.mark.skipautograding
def test_flake8_nb():
# Get the repository directory
current_dir = Path(__file__).resolve().parents[1]
Expand Down
Loading