Skip to content

Commit

Permalink
update para o gerenciador de dependecias 'poetry'
Browse files Browse the repository at this point in the history
  • Loading branch information
gustavodsantos committed Nov 10, 2024
1 parent 7b156dd commit 77385f4
Show file tree
Hide file tree
Showing 27 changed files with 1,146 additions and 829 deletions.
3 changes: 0 additions & 3 deletions .flake8

This file was deleted.

39 changes: 18 additions & 21 deletions .github/workflows/django_ci.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,12 @@
name: Python application
name: Django CI

on:
pull_request:
push:
branches:
- main

jobs:
build:
env:
PIPENV_NO_INHERIT: 1
PIPENV_IGNORE_VIRTUALENVS: 1
runs-on: ubuntu-latest

services:
Expand All @@ -23,25 +19,26 @@ jobs:
ports: [ '5432:5432' ]

steps:
- uses: actions/checkout@v2
- name: Set up Python 3.11
uses: actions/setup-python@v4
- uses: actions/checkout@v3
with:
python-version: '3.11'
fetch-depth: 1

- name: Install dependencies
run: |
pip install pipenv
pipenv sync --dev
- name: Setup Python
uses: actions/setup-python@v3
with:
python-version: "3.12"

- name: Lint with flake8
- name: Install dependencies (using poetry)
run: |
pipenv run flake8 .
python -m pip install --upgrade pip
python -m pip install poetry
poetry install --with dev --sync
- name: Copying configurations
run: |
cp contrib/env-sample .env
- name: Lint
run: poetry run task lint

- name: Test with pytest
run: |
pipenv run pytest --cache-clear
- name: Copy instance config variables
run: cp contrib/env-sample .env

- name: Run testes do Django com cobertura
run: poetry run pytest pypro --cov=pypro --cov-fail-under=20
10 changes: 5 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -152,11 +152,11 @@ dmypy.json
# Cython debug symbols
cython_debug/

# PyCharm
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
# and can be added to the global gitignore or merged into this file. For a more nuclear
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
PyCharm
JetBrains specific template is maintained in a separate JetBrains.gitignore that can
be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
and can be added to the global gitignore or merged into this file. For a more nuclear
option (not recommended) you can uncomment the following to ignore the entire idea folder.
.idea/

# postgres files for local developement
Expand Down
28 changes: 0 additions & 28 deletions Pipfile

This file was deleted.

Loading

0 comments on commit 77385f4

Please sign in to comment.