Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 35.2k
gh-110793: Add CI job that runs tests with an installed build#152664
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
base:main
Are you sure you want to change the base?
Changes from all commits
9a73e26caf7b264d5bbd086e64ee7961ebbe62fc5aa0cb79cFile filter
Filter by extension
Conversations
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Uh oh!
There was an error while loading. Please reload this page.
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,51 @@ | ||||||
| name: Reusable Ubuntu (Installed) | ||||||
| on: | ||||||
| workflow_call: | ||||||
| inputs: | ||||||
| os: | ||||||
| description: OS to run the job | ||||||
| required: true | ||||||
| type: string | ||||||
| permissions: | ||||||
| contents: read | ||||||
| env: | ||||||
| FORCE_COLOR: 1 | ||||||
| jobs: | ||||||
| build-install-test: | ||||||
| name: build, install and test (${{ inputs.os }}) | ||||||
| runs-on: ${{ inputs.os }} | ||||||
| timeout-minutes: 60 | ||||||
| env: | ||||||
| PYTHONSTRICTEXTENSIONBUILD: 1 | ||||||
| steps: | ||||||
| - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | ||||||
| with: | ||||||
| persist-credentials: false | ||||||
| - name: Runner image version | ||||||
| run: echo "IMAGE_OS_VERSION=${ImageOS}-${ImageVersion}" >> "$GITHUB_ENV" | ||||||
| - name: Register gcc problem matcher | ||||||
| run: echo "::add-matcher::.github/problem-matchers/gcc.json" | ||||||
| - name: Set install dir | ||||||
| run: | ||||||
| echo "INSTALL_DIR=$(realpath "${GITHUB_WORKSPACE}/../installed-python")" >> "$GITHUB_ENV" | ||||||
| - name: Install dependencies | ||||||
| run: sudo ./.github/workflows/posix-deps-apt.sh | ||||||
| - name: Configure CPython | ||||||
| run: ./configure --config-cache --with-pydebug --prefix="$INSTALL_DIR" | ||||||
| - name: Build CPython | ||||||
| run: make -j | ||||||
| - name: Install CPython | ||||||
| run: make install | ||||||
| - name: Set installed interpreter | ||||||
| run: | | ||||||
| ldversion=$(./python -c 'import sysconfig; print(sysconfig.get_config_var("LDVERSION"))') | ||||||
Member There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
MemberAuthor There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bash doesn’t split words on the RHS of an assignment. See this discussion for more information. | ||||||
| echo "INSTALLED_PYTHON=${INSTALL_DIR}/bin/python${ldversion}" >> "$GITHUB_ENV" | ||||||
| - name: Display build info | ||||||
| run: | | ||||||
| "$INSTALLED_PYTHON" -m test.pythoninfo | ||||||
| - name: Test the installed Python | ||||||
| run: xvfb-run "$INSTALLED_PYTHON" -m test -j0 --fast-ci --timeout=900 | ||||||
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.