| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 21c5f87 commit 6b54890
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -12,38 +12,61 @@ jobs: | |||
| 12 | 12 | SHELLOPTS: igncr | |
| 13 | 13 | TMP: "/tmp" | |
| 14 | 14 | TEMP: "/tmp" | |
| 15 | + defaults: | ||
| 16 | + run: | ||
| 17 | + shell: bash.exe -eo pipefail -o igncr "{0}" | ||
| 15 | 18 | ||
| 16 | 19 | steps: | |
| 17 | 20 | - name: Force LF line endings | |
| 18 | 21 | run: git config --global core.autocrlf input | |
| 22 | + | ||
| 19 | 23 | - uses: actions/checkout@v4 | |
| 20 | 24 | with: | |
| 21 | 25 | fetch-depth: 9999 | |
| 26 | + | ||
| 22 | 27 | - uses: cygwin/cygwin-install-action@v4 | |
| 23 | 28 | with: | |
| 24 | 29 | packages: python39 python39-pip python39-virtualenv git | |
| 30 | + | ||
| 31 | + - name: Show python and git versions | ||
| 32 | + run: | | ||
| 33 | + set -x | ||
| 34 | + /usr/bin/python --version | ||
| 35 | + /usr/bin/git version | ||
| 36 | + | ||
| 25 | 37 | - name: Tell git to trust this repo | |
| 26 | - shell: bash.exe -eo pipefail -o igncr "{0}" | ||
| 27 | 38 | run: | | |
| 28 | 39 | /usr/bin/git config --global --add safe.directory "$(pwd)" | |
| 29 | - - name: Install dependencies and prepare tests | ||
| 30 | - shell: bash.exe -eo pipefail -o igncr "{0}" | ||
| 40 | + | ||
| 41 | + - name: Prepare this repo for tests | ||
| 31 | 42 | run: | | |
| 32 | 43 | set -x | |
| 33 | - /usr/bin/python -m pip install --upgrade pip setuptools wheel | ||
| 34 | - /usr/bin/python --version; /usr/bin/git --version | ||
| 44 | + | ||
| 35 | 45 | /usr/bin/git submodule update --init --recursive | |
| 36 | 46 | /usr/bin/git fetch --tags | |
| 37 | - /usr/bin/python -m pip install -r requirements.txt | ||
| 38 | - /usr/bin/python -m pip install -r test-requirements.txt | ||
| 39 | 47 | TRAVIS=yes ./init-tests-after-clone.sh | |
| 48 | + | ||
| 49 | + - name: Further prepare git configuration for tests | ||
| 50 | + run: | | ||
| 51 | + set -x | ||
| 52 | + | ||
| 40 | 53 | /usr/bin/git config --global user.email "travis@ci.com" | |
| 41 | 54 | /usr/bin/git config --global user.name "Travis Runner" | |
| 42 | 55 | # If we rewrite the user's config by accident, we will mess it up | |
| 43 | 56 | # and cause subsequent tests to fail | |
| 44 | 57 | cat test/fixtures/.gitconfig >> ~/.gitconfig | |
| 58 | + | ||
| 59 | + - name: Update PyPA packages | ||
| 60 | + run: | | ||
| 61 | + set -x | ||
| 62 | + /usr/bin/python -m pip install --upgrade pip setuptools wheel | ||
| 63 | + | ||
| 64 | + - name: Install project and test dependencies | ||
| 65 | + run: | | ||
| 66 | + set -x | ||
| 67 | + /usr/bin/python -m pip install ".[test]" | ||
| 68 | + | ||
| 45 | 69 | - name: Test with pytest | |
| 46 | - shell: bash.exe -eo pipefail -o igncr "{0}" | ||
| 47 | 70 | run: | | |
| 71 | + set -x | ||
| 48 | 72 | /usr/bin/python -m pytest | |
| 49 | - continue-on-error: false | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -15,42 +15,70 @@ jobs: | |||
| 15 | 15 | strategy: | |
| 16 | 16 | fail-fast: false | |
| 17 | 17 | matrix: | |
| 18 | - python-version: [3.7, 3.8, 3.9, "3.10", "3.11"] | ||
| 18 | + python-version: ["3.7", "3.8", "3.9", "3.10", "3.11", "3.12"] | ||
| 19 | + include: | ||
| 20 | + - experimental: false | ||
| 21 | + - python-version: "3.12" | ||
| 22 | + experimental: true | ||
| 19 | 23 | ||
| 20 | 24 | steps: | |
| 21 | 25 | - uses: actions/checkout@v4 | |
| 22 | 26 | with: | |
| 23 | 27 | fetch-depth: 9999 | |
| 28 | + | ||
| 24 | 29 | - name: Set up Python ${{ matrix.python-version }} | |
| 25 | 30 | uses: actions/setup-python@v4 | |
| 26 | 31 | with: | |
| 27 | 32 | python-version: ${{ matrix.python-version }} | |
| 28 | - - name: Install dependencies and prepare tests | ||
| 33 | + allow-prereleases: ${{ matrix.experimental }} | ||
| 34 | + | ||
| 35 | + - name: Show python and git versions | ||
| 36 | + run: | | ||
| 37 | + set -x | ||
| 38 | + python --version | ||
| 39 | + git version | ||
| 40 | + | ||
| 41 | + - name: Prepare this repo for tests | ||
| 29 | 42 | run: | | |
| 30 | 43 | set -x | |
| 31 | 44 | ||
| 32 | - python -m pip install --upgrade pip setuptools wheel | ||
| 33 | - python --version; git --version | ||
| 34 | 45 | git submodule update --init --recursive | |
| 35 | 46 | git fetch --tags --force | |
| 36 | - | ||
| 37 | - pip install -r requirements.txt | ||
| 38 | - pip install -r test-requirements.txt | ||
| 39 | 47 | TRAVIS=yes ./init-tests-after-clone.sh | |
| 40 | 48 | ||
| 49 | + - name: Prepare git configuration for tests | ||
| 50 | + run: | | ||
| 51 | + set -x | ||
| 52 | + | ||
| 41 | 53 | git config --global user.email "travis@ci.com" | |
| 42 | 54 | git config --global user.name "Travis Runner" | |
| 43 | 55 | # If we rewrite the user's config by accident, we will mess it up | |
| 44 | 56 | # and cause subsequent tests to fail | |
| 45 | 57 | cat test/fixtures/.gitconfig >> ~/.gitconfig | |
| 46 | 58 | ||
| 59 | + - name: Update PyPA packages | ||
| 60 | + run: | | ||
| 61 | + set -x | ||
| 62 | + | ||
| 63 | + python -m pip install --upgrade pip | ||
| 64 | + if pip freeze --all | grep --quiet '^setuptools=='; then | ||
| 65 | + # Python prior to 3.12 ships setuptools. Upgrade it if present. | ||
| 66 | + python -m pip install --upgrade setuptools | ||
| 67 | + fi | ||
| 68 | + python -m pip install --upgrade wheel | ||
| 69 | + | ||
| 70 | + - name: Install project and test dependencies | ||
| 71 | + run: | | ||
| 72 | + set -x | ||
| 73 | + pip install ".[test]" | ||
| 74 | + | ||
| 47 | 75 | - name: Check types with mypy | |
| 48 | - # With new versions of pypi new issues might arise. This is a problem if there is nobody able to fix them, | ||
| 49 | - # so we have to ignore errors until that changes. | ||
| 50 | - continue-on-error: true | ||
| 51 | 76 | run: | | |
| 52 | 77 | set -x | |
| 53 | 78 | mypy -p git | |
| 79 | + # With new versions of mypy new issues might arise. This is a problem if there is nobody able to fix them, | ||
| 80 | + # so we have to ignore errors until that changes. | ||
| 81 | + continue-on-error: true | ||
| 54 | 82 | ||
| 55 | 83 | - name: Test with pytest | |
| 56 | 84 | run: | | |
| Back | FazBrowse Home | New Git URL |
0 commit comments