This repository has been archived by the owner on Sep 23, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
166 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,3 +2,7 @@ | |
*.db | ||
*.swp | ||
*.swo | ||
.tox/ | ||
.coverage | ||
sktm.egg-info | ||
.pytest_cache |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,12 @@ | ||
language: python | ||
python: | ||
- "2.7" | ||
env: | ||
- TOX_ENV=py27,flake8,pylint | ||
install: | ||
- pip install -U pip | ||
- pip install -r requirements.txt | ||
- pip install -r test-requirements.txt | ||
# Install sktm using pip to ensure dependencies are downloaded correctly. | ||
- pip install . | ||
- pip install coveralls tox | ||
script: | ||
# Make sure all Python files are loadable | ||
- find -name '*.py' | xargs -l1 -IFILE python -c 'import imp; imp.load_source("", "FILE")' | ||
# Check coding style | ||
- flake8 --show-source . | ||
- pylint tests | ||
- coverage run --source=sktm,tests -m pytest -v -s . | ||
- coverage report -m --omit="*/tests*" | ||
- coveralls | ||
- tox -e $TOX_ENV | ||
- pip uninstall -y sktm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
include README.md | ||
include LICENSE | ||
include sktm/* | ||
include tests/* | ||
include db_migrations/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
[metadata] | ||
name = sktm | ||
description = "Sonic Kernel Testing Manager" | ||
long_description = file: README.md | ||
version = 1 | ||
author = Red Hat, Inc. | ||
license = GPLv2+ | ||
|
||
[options] | ||
# Automatically find all files beneath the sktm directory and include them. | ||
packages = find: | ||
# Parse the MANIFEST.in file and include those files, too. | ||
include_package_data = True | ||
|
||
install_requires = flake8 | ||
dateutils | ||
enum34 | ||
jenkinsapi | ||
junit_xml | ||
requests | ||
pylint | ||
mock | ||
|
||
[options.entry_points] | ||
console_scripts = | ||
sktm = sktm.executable:main | ||
|
||
[options.packages.find] | ||
# Don't include the /tests directory when we search for python files. | ||
exclude = | ||
tests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/usr/bin/env python | ||
# Copyright (c) 2018 Red Hat, Inc. All rights reserved. This copyrighted | ||
# material is made available to anyone wishing to use, modify, copy, or | ||
# redistribute it subject to the terms and conditions of the GNU General | ||
# Public License v.2 or later. | ||
# | ||
# This program is distributed in the hope that it will be useful, but WITHOUT | ||
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS | ||
# FOR A PARTICULAR PURPOSE. See the GNU General Public License for more | ||
# details. | ||
# | ||
# You should have received a copy of the GNU General Public License | ||
# along with this program; if not, write to the Free Software Foundation, Inc., | ||
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||
"""Install sktm using setuptools.""" | ||
from setuptools import setup | ||
|
||
setup() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
[tox] | ||
envlist = | ||
py27 | ||
flake8 | ||
pylint | ||
|
||
[testenv] | ||
passenv = TRAVIS TRAVIS_* | ||
deps = | ||
coverage | ||
mock | ||
coveralls | ||
pytest | ||
commands = | ||
coverage run --branch --source=sktm -m pytest -v -s tests | ||
coverage report -m | ||
coveralls | ||
|
||
[testenv:flake8] | ||
passenv = CI TRAVIS TRAVIS_* | ||
basepython = | ||
python2.7 | ||
commands = | ||
flake8 --show-source . | ||
|
||
[testenv:pylint] | ||
passenv = CI TRAVIS TRAVIS_* | ||
basepython = | ||
python2.7 | ||
commands = | ||
pylint tests |