Django 테스트기

1474 단어 actionshackathon

내 워크플로우


Note: #Django 테스트원

제출 범주:


Note:#이상한 와일드카드

Yaml 파일 또는 코드 링크


#This workflow will install Python dependencies, run tests and lint with a single version of Python
#
 #For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions

name: Python application
on:
  push:
    branches: [master]
  pull_request:
    branches: [master]
jobs:
  build:
    runs-on: ubuntu-latest
    services:
      postgres:
        image: postgres:10.8
        env:
          POSTGRES_USER: postgres
          POSTGRES_PASSWORD: postgres
          POSTGRES_DB: github_actions
        ports:
          - 5432:5432
        options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
    steps:
      - uses: actions/checkout@v2
      - name: Set up Python 3.8
        uses: actions/setup-python@v2
        with:
          python-version: 3.8
      - name: psycopg2 prerequisites
        run: sudo apt-get install python-dev libpq-dev
      - name: Install dependencies
        run: |
          python -m pip install --upgrade pip
          pip install -r requirements.txt
      - name: Run migrations
        run: python manage.py migrate
      - name: Run tests
        run: python manage.py test

좋은 웹페이지 즐겨찾기