chore(textEdit)!: Implement auto-scroll follow modes for text editor and improve tests #2027
Workflow file for this run
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
| name: Testing | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| on: | |
| push: | |
| branches: [ main ] | |
| pull_request: | |
| branches: [ main ] | |
| jobs: | |
| test-autogen: | |
| name: Test AutoGen Code | |
| runs-on: self-hosted | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| ref: ${{ github.sha }} | |
| - name: Check Autogen Code is up to dated | |
| run: | | |
| PYTHONPATH=libs/pyTermTk tools/autogenForwarded.py --apply | |
| if [[ $(git status --porcelain) ]] ; then | |
| git diff | |
| echo "❌ PR failed due to missing release files:" | |
| echo " - run: PYTHONPATH=libs/pyTermTk tools/autogenForwarded.py --apply" | |
| echo " and push the generated files" | |
| exit 1 | |
| else | |
| echo "✅ - Release Clean" | |
| fi | |
| test-pyTermTk: | |
| name: Test pyTermTk | |
| # runs-on: ubuntu-latest | |
| runs-on: self-hosted | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ['3.9', '3.10', '3.11', '3.12', '3.13', '3.14'] | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v3 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Check allowed imports | |
| run: | | |
| # Stop the build if some unexpected import is found | |
| tools/check.import.sh | |
| - name: Install dependencies | |
| shell: bash | |
| run: | | |
| python -m pip install --upgrade pip | |
| python -m pip install uv | |
| uv venv | |
| uv pip install -e '.[test]' --no-cache | |
| - name: Lint with flake8 | |
| run: | | |
| # stop the build if there are Python syntax errors or undefined names | |
| .venv/bin/flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics --exclude .venv,build,tmp | |
| # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide | |
| # flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics | |
| - name: pytest | |
| run: | | |
| DDDD=$(pwd) | |
| .venv/bin/pytest ${DDDD}/tests/pytest | |
| .venv/bin/pytest ${DDDD}/apps | |
| - name: Dumb Smoke Test | |
| run: | | |
| # To fix a folder permissin issue let's try to run the test from /tmp | |
| DDDD=$(pwd) | |
| # Download the input test | |
| mkdir -p tmp | |
| wget -O tmp/test.input.001.bin https://github.com/ceccopierangiolieugenio/binaryRepo/raw/master/pyTermTk/tests/test.input.001.bin | |
| wget -O tmp/test.input.002.bin https://github.com/ceccopierangiolieugenio/binaryRepo/raw/master/pyTermTk/tests/test.input.002.bin | |
| wget -O tmp/test.input.003.bin https://github.com/ceccopierangiolieugenio/binaryRepo/raw/master/pyTermTk/tests/test.input.003.bin | |
| .venv/bin/pytest ${DDDD}/tests/pytest/run_* |