diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 963935b..80e3080 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,8 +35,32 @@ jobs: - uses: julia-actions/cache@v2 - uses: julia-actions/julia-buildpkg@v1 - uses: julia-actions/julia-runtest@v1 + if: matrix.version != 'pre' with: depwarn: error + - name: Run tests (pre, verbose) + if: matrix.version == 'pre' + id: pre_test + run: | + julia --depwarn=error --project -e 'using Pkg; Pkg.test()' 2>&1 | tee /tmp/test-output.txt || true + echo '```' >> $GITHUB_STEP_SUMMARY + tail -100 /tmp/test-output.txt >> $GITHUB_STEP_SUMMARY + echo '```' >> $GITHUB_STEP_SUMMARY + grep -q "Testing DynamicPolynomials tests passed" /tmp/test-output.txt + - name: Post test output as PR comment + if: failure() && matrix.version == 'pre' && github.event_name == 'pull_request' + uses: actions/github-script@v7 + with: + script: | + const fs = require('fs'); + const output = fs.readFileSync('/tmp/test-output.txt', 'utf8'); + const last200 = output.split('\n').slice(-200).join('\n'); + await github.rest.issues.createComment({ + owner: context.repo.owner, + repo: context.repo.repo, + issue_number: context.issue.number, + body: `### Julia pre test failure\n\`\`\`\n${last200}\n\`\`\`` + }); - uses: julia-actions/julia-processcoverage@v1 - uses: codecov/codecov-action@v4 with: diff --git a/test/runtests.jl b/test/runtests.jl index 36f20ea..56edbeb 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -1,7 +1,12 @@ +@info "Julia version: $(VERSION)" +@info "depwarn setting: $(Base.JLOptions().depwarn)" using DynamicPolynomials +@info "DynamicPolynomials loaded" using MultivariatePolynomials +@info "MultivariatePolynomials loaded" using Test using LinearAlgebra +@info "All packages loaded, starting tests" function alloc_test_lt(f, n) f() # compile