|
1 | 1 | name: Run tests
|
2 | 2 | on: [push]
|
3 | 3 |
|
| 4 | +x-base: &base |
| 5 | + steps: |
| 6 | + - uses: actions/checkout@master |
| 7 | + - run: git clone https://github.com/django/django.git --depth=1 ${GITHUB_WORKSPACE}/django |
| 8 | + - run: docker-compose pull --include-deps ${{ matrix.compose_app }} |
| 9 | + - run: DJANGO_PATH=${GITHUB_WORKSPACE}/django docker-compose build --pull ${{ matrix.compose_app }} |
| 10 | + - run: DJANGO_PATH=${GITHUB_WORKSPACE}/django docker-compose run ${{ matrix.compose_app }} |
| 11 | + |
4 | 12 | jobs:
|
| 13 | + docs: |
| 14 | + name: ${{ matrix.compose_app }} |
| 15 | + strategy: |
| 16 | + matrix: |
| 17 | + compose_app: |
| 18 | + - flake8 |
| 19 | + - docs |
| 20 | + runs-on: ubuntu-latest |
| 21 | + <<: *base |
| 22 | + |
| 23 | + sqlite: |
| 24 | + name: sqlite |
| 25 | + strategy: |
| 26 | + matrix: |
| 27 | + python_version: |
| 28 | + - 3.6 |
| 29 | + - 3.7 |
| 30 | + runs-on: ubuntu-latest |
| 31 | + steps: |
| 32 | + - uses: actions/checkout@master |
| 33 | + - run: git clone https://github.com/django/django.git --depth=1 ${GITHUB_WORKSPACE}/django |
| 34 | + - run: docker-compose pull --include-deps sqlite |
| 35 | + - run: DJANGO_PATH=${GITHUB_WORKSPACE}/django PYTHON_VERSION=${{ matrix.python_version }} docker-compose build --pull sqlite |
| 36 | + - run: DJANGO_PATH=${GITHUB_WORKSPACE}/django PYTHON_VERSION=${{ matrix.python_version }} docker-compose run sqlite |
| 37 | + |
| 38 | + postgres: |
| 39 | + name: postgres |
| 40 | + strategy: |
| 41 | + matrix: |
| 42 | + python_version: |
| 43 | + - 3.6 |
| 44 | + - 3.7 |
| 45 | + db_version: |
| 46 | + - 9.5 |
| 47 | + - 9.6 |
| 48 | + - 10 |
| 49 | + - 11 |
| 50 | + runs-on: ubuntu-latest |
| 51 | + steps: |
| 52 | + - uses: actions/checkout@master |
| 53 | + - run: git clone https://github.com/django/django.git --depth=1 ${GITHUB_WORKSPACE}/django |
| 54 | + - run: docker-compose pull --include-deps postgres |
| 55 | + - run: DJANGO_PATH=${GITHUB_WORKSPACE}/django docker-compose build --pull postgres |
| 56 | + env: |
| 57 | + PYTHON_VERSION: ${{ matrix.python_version }} |
| 58 | + POSTGRES_VERSION: ${{ matrix.db_version }} |
| 59 | + - run: DJANGO_PATH=${GITHUB_WORKSPACE}/django docker-compose run postgres |
| 60 | + env: |
| 61 | + PYTHON_VERSION: ${{ matrix.python_version }} |
| 62 | + POSTGRES_VERSION: ${{ matrix.db_version }} |
| 63 | + |
| 64 | + mysql: |
| 65 | + name: mysql |
| 66 | + strategy: |
| 67 | + matrix: |
| 68 | + python_version: |
| 69 | + - 3.6 |
| 70 | + - 3.7 |
| 71 | + db_version: |
| 72 | + - 5.6 |
| 73 | + - 5.7 |
| 74 | + - 8.0 |
| 75 | + runs-on: ubuntu-latest |
| 76 | + steps: |
| 77 | + - uses: actions/checkout@master |
| 78 | + - run: git clone https://github.com/django/django.git --depth=1 ${GITHUB_WORKSPACE}/django |
| 79 | + - run: docker-compose pull --include-deps mysql |
| 80 | + - run: DJANGO_PATH=${GITHUB_WORKSPACE}/django docker-compose build --pull mysql |
| 81 | + env: |
| 82 | + PYTHON_VERSION: ${{ matrix.python_version }} |
| 83 | + MYSQL_VERSION: ${{ matrix.db_version }} |
| 84 | + - run: DJANGO_PATH=${GITHUB_WORKSPACE}/django docker-compose run mysql |
| 85 | + env: |
| 86 | + PYTHON_VERSION: ${{ matrix.python_version }} |
| 87 | + MYSQL_VERSION: ${{ matrix.db_version }} |
| 88 | + |
5 | 89 | mariadb:
|
6 |
| - runs-on: ${{ matrix.os }} |
| 90 | + name: mariadb |
7 | 91 | strategy:
|
8 | 92 | matrix:
|
9 |
| - os: [ubuntu-18.04] |
10 |
| - node: [4, 6, 8, 10] |
| 93 | + python_version: |
| 94 | + - 3.6 |
| 95 | + db_version: |
| 96 | + - 10.1 |
11 | 97 | include:
|
12 |
| - - os: windows-2016 |
13 |
| - node: [4, 6] |
14 |
| - npm: 2 |
| 98 | + - db_version: 10.3 |
| 99 | + python_version: 3.7 |
| 100 | + runs-on: ubuntu-latest |
15 | 101 | steps:
|
16 |
| - - name: Hello world |
17 |
| - uses: actions/hello-world-javascript-action@v1 |
18 |
| - with: |
19 |
| - who-to-greet: 'Mona the Octocat' |
20 |
| - id: hello |
21 |
| - # This step prints an output (time) from the previous step's action. |
22 |
| - - name: Echo the greeting's time |
23 |
| - run: echo 'The time was ${{ steps.hello.outputs.time }}.' |
| 102 | + - uses: actions/checkout@master |
| 103 | + - run: git clone https://github.com/django/django.git --depth=1 ${GITHUB_WORKSPACE}/django |
| 104 | + - run: docker-compose pull --include-deps mariadb |
| 105 | + - run: DJANGO_PATH=${GITHUB_WORKSPACE}/django docker-compose build --pull mariadb |
| 106 | + env: |
| 107 | + PYTHON_VERSION: ${{ matrix.python_version }} |
| 108 | + MARIADB_VERSION: ${{ matrix.db_version }} |
| 109 | + - run: DJANGO_PATH=${GITHUB_WORKSPACE}/django docker-compose run mariadb |
| 110 | + env: |
| 111 | + PYTHON_VERSION: ${{ matrix.python_version }} |
| 112 | + MARIADB_VERSION: ${{ matrix.db_version }} |
0 commit comments