From bc1b131a1e8c35f14a68c56dc6e048f4f3063e55 Mon Sep 17 00:00:00 2001 From: Stephanos Ioannidis Date: Thu, 3 Oct 2024 23:41:23 +0900 Subject: [PATCH] [TEST] Add test workflow --- .github/workflows/test.yml | 84 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 .github/workflows/test.yml diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..9d0edc3 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,84 @@ +name: Test + +on: + push: + branches: + - main-test + - v*-branch + pull_request: + branches: + - main-test + - v*-branch + workflow_call: + +concurrency: + group: ${{ github.ref }} + cancel-in-progress: true + +jobs: + test: + name: Test (Python ${{ matrix.target.python }}) + runs-on: ${{ matrix.target.builder }} + + strategy: + fail-fast: false + matrix: + target: + # Python 3.6 + - python: '3.6' + builder: ubuntu-22.04 + # Python 3.7 + - python: '3.7' + builder: ubuntu-22.04 + # Python 3.8 + - python: '3.8' + builder: ubuntu-22.04 + # Python 3.9 + - python: '3.9' + builder: ubuntu-22.04 + # Python 3.10 + - python: '3.10' + builder: ubuntu-22.04 + # Python 3.11 + - python: '3.11' + builder: ubuntu-22.04 + # Python 3.12 + - python: '3.12' + builder: ubuntu-22.04 + + steps: + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: ${{ matrix.target.python }} + + - name: Check Python version + run: | + set -x + python --version + pip --version + python -c "import platform; print(platform.architecture())" + + - name: Install Python dependencies + run: | + pip install --user setuptools wheel + + - name: Check out Linux source code + uses: actions/checkout@v4 + with: + repository: torvalds/linux + ref: v5.4 + + - name: Check out Kconfiglib source code + uses: actions/checkout@v4 + with: + path: Kconfiglib + + - name: Apply Linux Kconfig Makefile patch + run: | + git apply Kconfiglib/makefile.patch + + - name: Run testsuite + run: | + python Kconfiglib/testsuite.py + # Kconfiglib/tests/reltest