Add PR test CI + modernize test suite to pytest#11
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
jl2py had no PR CI (only
wheels.ymlon tags). This adds apull_requesttestworkflow and modernizes the test suite to idiomatic pytest.
CI (
.github/workflows/test.yml): on PR, set up Julia 1.12.6 + Python 3.12,makelibjl2py,pip install numpy pytest, runpytest -v out/jl2py/tests.pytest conversion (the suite was script-style with per-file
setup()/main()):tests/conftest.py— session-scopedjlfixture (the test functions already takejl).setup()/main()/__main__boilerplate from every file.test_struct.py— its struct definitions moved into a module-scoped autouse fixture.test_array.py— the 3 memory-wrap tests nowskipifcleanly when the experimentallibjulia-internalbuild isn't present (tracked in CI: add a JL2PY_INTERNAL build matrix cell for Memory wrap/alloc #8).test_identity.py(pointer-identity round-trip, PRD §4.3) andtest_exceptions.py(typed error mapping — BoundsError→IndexError, DomainError→ValueError, etc.).
Local run (Julia 1.12.6): 76 passed, 3 skipped, 0 failed.
Follow-ups filed: #5–#10.
🤖 Generated with Claude Code