Skip to content

Use pytest-prysk instead - #104

Merged
ctrueden merged 5 commits into
mainfrom
pytest-prysk
Oct 23, 2026
Merged

ctrueden merged 5 commits into
mainfrom
pytest-prysk

Conversation

@gselzer

@gselzer gselzer commented May 19, 2026

Copy link
Copy Markdown
Contributor

Was looking at adding it in #103 but it might be best to consider it separately first

@gselzer
gselzer force-pushed the pytest-prysk branch 3 times, most recently from 422b512 to 8e93dbe Compare May 20, 2026 17:50
gselzer and others added 3 commits October 23, 2026 13:21
Maybe. wrap has a little trouble still
Unlike the standalone prysk CLI, pytest-prysk does not point TMPDIR,
TEMP and TMP at a fresh per-test directory. Many .t files write to and
cd into "$TMPDIR", which is unset on most Linux systems (including CI
runners), so it expanded to "" and seven tests failed (config, coords,
info, javainfo, list, path, tree). On macOS, TMPDIR is set but shared,
so state leaked between runs (e.g. path.t's non-idempotent mkdir).

pytest-prysk items also do not participate in fixtures, so the autouse
_isolate_config_file fixture never applied to .t tests.

Add a pytest_runtest_call hook wrapper that, for prysk items only, sets
TMPDIR/TEMP/TMP to a fresh temporary directory, defaults COLOR=never and
NO_PROGRESS=1, and unsets JGO_CONFIG_FILE. This makes plain
`uv run pytest` behave the same as bin/test.sh, so bin/test.sh no longer
needs to set those variables.

With a working $TMPDIR, the example.t workaround is no longer needed,
so restore it to match main (its cleanup line still cds into $TMPDIR).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
ctrueden and others added 2 commits October 23, 2026 13:42
prysk runs .t files via /bin/sh, which Windows lacks. Previously,
bin/test.sh only ran prysk when the prysk command was found, which never
happened on the Windows CI runners, so the .t tests were silently skipped
there. Now that pytest-prysk collects them, skip them explicitly.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The prysk tests now run via pytest-prysk under uv run, which puts the
project venv's jgo first on the PATH.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@ctrueden
ctrueden marked this pull request as ready for review October 23, 2026 20:37

@ctrueden ctrueden left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent, thank you very much.

@ctrueden
ctrueden merged commit 44cbfb6 into main Oct 23, 2026
6 checks passed
@ctrueden
ctrueden deleted the pytest-prysk branch October 23, 2026 20:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants