Browse Source
* [python] Add tox for out of box test * Add `tox` for easy and complete test * Correct package data attribute * Add more dirs in flake8 ignore * Change GA from raw to tox * Fix env setter * Temp skip sanity * Rm not exists job * Add code test * fix * rm all need * fix * fix * fix * fix * fix * fix * Migrate pip upgrede to tox setting * Change install_commands to commands * fix config of install command * Add GA env to do that * Fix env error * Finial commit * remove duplicate * Change doc * Change dependence of ci * Change dependence of ci3.0.0/version-upgrade
Jiajie Zhong
3 years ago
committed by
GitHub
7 changed files with 153 additions and 59 deletions
@ -0,0 +1,48 @@ |
|||||||
|
# Licensed to the Apache Software Foundation (ASF) under one |
||||||
|
# or more contributor license agreements. See the NOTICE file |
||||||
|
# distributed with this work for additional information |
||||||
|
# regarding copyright ownership. The ASF licenses this file |
||||||
|
# to you under the Apache License, Version 2.0 (the |
||||||
|
# "License"); you may not use this file except in compliance |
||||||
|
# with the License. You may obtain a copy of the License at |
||||||
|
# |
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0 |
||||||
|
# |
||||||
|
# Unless required by applicable law or agreed to in writing, |
||||||
|
# software distributed under the License is distributed on an |
||||||
|
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
||||||
|
# KIND, either express or implied. See the License for the |
||||||
|
# specific language governing permissions and limitations |
||||||
|
# under the License. |
||||||
|
|
||||||
|
[tox] |
||||||
|
envlist = local-ci, lint, doc-build-test, code-test, py{36,37,38,39} |
||||||
|
|
||||||
|
[testenv] |
||||||
|
whitelist_externals = make |
||||||
|
|
||||||
|
[testenv:lint] |
||||||
|
extras = style |
||||||
|
commands = |
||||||
|
python -m isort --check . |
||||||
|
python -m black --check . |
||||||
|
python -m flake8 |
||||||
|
|
||||||
|
[testenv:code-test] |
||||||
|
extras = test |
||||||
|
# Run both tests and coverage |
||||||
|
commands = |
||||||
|
python -m pytest --cov=pydolphinscheduler --cov-config={toxinidir}/.coveragerc tests/ |
||||||
|
|
||||||
|
[testenv:doc-build-test] |
||||||
|
extras = doc |
||||||
|
commands = |
||||||
|
make -C {toxinidir}/docs clean |
||||||
|
make -C {toxinidir}/docs html |
||||||
|
|
||||||
|
[testenv:local-ci] |
||||||
|
extras = dev |
||||||
|
commands = |
||||||
|
{[testenv:lint]commands} |
||||||
|
{[testenv:code-test]commands} |
||||||
|
{[testenv:doc-build-test]commands} |
Loading…
Reference in new issue