Skip to content

Add a tests for building Python extensions #3

Add a tests for building Python extensions

Add a tests for building Python extensions #3

Workflow file for this run

name: e2e-extension
on:
pull_request:
paths-ignore:
- '**.md'
push:
branches:
- main
- releases/*
paths-ignore:
- '**.md'
workflow_dispatch:
permissions:
contents: read
jobs:
python-extension:
name: Test building extensions (Python ${{ matrix.python-version}}, ${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
python-version: ['3.9', 'pypy-3.9-v7.x']
steps:
- uses: actions/checkout@v4
- name: Setup Python
uses: ./
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
- name: Install dependencies
run: pip install setuptools
- name: Build extension
run: pip install .
working-directory: __tests__/data/extension/
- name: Check output
run: |
output=$(python3 -c "import helloworld; helloworld.say_hello('world')")
test "$output" == "Hello, world!"