Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
boromir674 committed Jun 6, 2022
1 parent 6e162b4 commit c9aa4d0
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 15 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ jobs:
echo "DIST_DIR=dist" >> $GITHUB_ENV
mkdir "$DIST_DIR"
mv ".tox/${DIST_DIR}/cookiecutter_python-${PKG_VERSION}.tar.gz" "${DIST_DIR}"
mv ".tox/${DIST_DIR}/cookiecutter_python-${PKG_VERSION}-py3-none-any.whl" "${DIST_DIR}"
mv ".tox/${DIST_DIR}/biskotaki-${PKG_VERSION}.tar.gz" "${DIST_DIR}"
mv ".tox/${DIST_DIR}/biskotaki-${PKG_VERSION}-py3-none-any.whl" "${DIST_DIR}"
tox -e check -vv -s false
- name: Upload Source & Wheel distributions as Artefacts
Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
Changelog
=========

0.0.1 (2022-06-01)
0.0.1 (2022-06-06)
=======================================

| This is the first ever release of the **biskotaki** Python Package.
Expand Down
2 changes: 1 addition & 1 deletion tests/smoke_test.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
def test_smoke_is_not_risingfrom_module():
def test_import_module():
import biskotaki

assert biskotaki is not None
44 changes: 33 additions & 11 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ setenv =
COVERAGE_FILE = {toxworkdir}{/}.coverage.{envname}
TEST_STATUS_DIR = {envtmpdir}
PYPY3323BUG = 1
black,lint,isort: LINT_ARGS = "src tests scripts"
extras =
test
commands =
Expand All @@ -59,7 +60,7 @@ commands =

# PATH
[testenv:{py311, py310, py39, py38, py37, py36, pypy3}-path{, -linux, -macos, -windows}]
description = "Add Source Code to Path & Test"
description = Add Source Code to Path & Test
setenv =
{[testenv]setenv}
PYTHONPATH = {toxinidir}{/}src{:}{toxinidir}{/}tests
Expand All @@ -71,11 +72,11 @@ commands =

# SDIST
[testenv:{py311, py310, py39, py38, py37, py36, pypy3}-sdist{, -linux, -macos, -windows}]
description = "Install as Source Distribution & Test"
description = Install as Source Distribution & Test

# WHEEL
[testenv:{py311, py310, py39, py38, py37, py36, pypy3}-wheel{, -linux, -macos, -windows}]
description = "Install as Wheel & Test"
description = Install as Wheel & Test
skip_install = true
changedir = {toxinidir}
commands_pre =
Expand All @@ -87,10 +88,28 @@ commands =

# DEV
[testenv:{py311, py310, py39, py38, py37, py36, pypy3}-dev{, -linux, -macos, -windows}]
description = "Install in 'edit' mode & Test"
description = Install in 'edit' mode & Test
usedevelop = true


# Designed for local developement
[testenv:dev]
description = Using `python3` in PATH: Install in 'edit' mode & Test
basepython = {env:TOXPYTHON:python3}
usedevelop = true
commands = pytest -ra {posargs:-n auto} {toxinidir}{/}tests

[testenv:dev-cov]
description = Using `python3` in PATH: Install in 'edit' mode, Test & measure Coverage
basepython = {env:TOXPYTHON:python3}
usedevelop = true
commands =
pytest -ra --cov --cov-report=term-missing \
--cov-report=html:{envdir}/htmlcov --cov-context=test \
--cov-report=xml:{toxworkdir}/coverage.{envname}.xml \
{posargs:-n auto} {toxinidir}{/}tests


[testenv:coverage]
description = combine coverage from test environments
passenv =
Expand All @@ -110,7 +129,7 @@ commands =
depends = {py311, py310, py39, py38, py37, py36}{, -path, -sdist, -wheel, -dev}


[testenv:dev]
[testenv:dev-env]
description = generate a DEV environment
usedevelop = true
extras =
Expand Down Expand Up @@ -266,10 +285,11 @@ skip_install = true
changedir = {toxinidir}
commands_pre = python -c 'import os; f = ".pylintrc"; exec("if os.path.exists(f):\n os.rename(f, \".pylintrc-bak\")")'
commands =
prospector tests
prospector src
isort {env:APPLY_LINT:--check} .
black {env:APPLY_LINT:--check} -S --config pyproject.toml tests src
prospector tests
prospector scripts
isort {posargs:{env:APPLY_LINT:--check}} "{env:LINT_ARGS:.}"
black {posargs:{env:APPLY_LINT:--check}} -S --config pyproject.toml "{env:LINT_ARGS:.}"
commands_post = python -c 'import os; f = ".pylintrc-bak"; exec("if os.path.exists(f):\n os.rename(f, \".pylintrc\")")'


Expand All @@ -278,13 +298,15 @@ description = black ops
deps = black
skip_install = true
changedir = {toxinidir}
commands = black {posargs} -S --config pyproject.toml tests src
commands = black {posargs:{env:APPLY_BLACK:--check}} --skip-string-normalization \
--config pyproject.toml "{env:LINT_ARGS:.}"


[testenv:isort]
descript = isort
description = isort
deps = isort >= 5.0.0
skip_install = true
commands = isort {posargs} {toxinidir}
commands = isort {posargs:{env:APPLY_ISORT:--check}} "{env:LINT_ARGS:.}"


## Code Static Analysis
Expand Down

0 comments on commit c9aa4d0

Please sign in to comment.