Skip to content

Commit

Permalink
applied gha changes in plantmeter
Browse files Browse the repository at this point in the history
  • Loading branch information
vokimon committed Feb 3, 2022
1 parent e582120 commit b1d0b98
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 9 deletions.
18 changes: 10 additions & 8 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,24 +14,26 @@ jobs:
matrix:
python-version:
- '2.7' # production
- '3.5'
- '3.8'
- '3.9'
mongodb-version:
- 2
name: Python ${{ matrix.python-version }}
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: install system dependencies
run: |
wget -qO - https://www.mongodb.org/static/pgp/server-3.2.asc | sudo apt-key add -
echo "deb http://repo.mongodb.org/apt/ubuntu trusty/mongodb-org/3.2 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.2.list
sudo apt update
sudo apt install mongodb-org-server
- name: Start MongoDB
uses: supercharge/mongodb-github-action@1.7.0
with:
mongodb-version: ${{ matrix.mongodb-version }}
mongodb-replica-set: test-rs
- name: Install dependencies
run: |
pip install https://files.pythonhosted.org/packages/3e/5c/2867e46f03d2fcc3d014a02eeb11ec55f3f8d9eddddcc5578ae8457f84f8/ERPpeek-1.7.1-py2.py3-none-any.whl
pip install pytest-cov pytest
./setup.py develop
- uses: BSFishy/pip-action@v1
with:
Expand All @@ -40,7 +42,7 @@ jobs:
git+https://github.com/som-energia/plantmeter.git@master
- name: Unit tests
run: |
coverage run --source generationkwh ./setup.py test
pytest
- name: Coveralls
uses: AndreMiras/coveralls-python-action@develop
Expand Down
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,12 @@
'consolemsg>=0.3',
'somutils',
'mock<4' if py2 else '', # TODO: remove indirect dependency for Py2
'pytest',
'pytest-cov',
# 'libfacturacioatr',
],
include_package_data = True,
test_suite = 'generationkwh',
# test_runner = 'colour_runner.runner.ColourTextTestRunner',
classifiers = [
'Programming Language :: Python',
'Programming Language :: Python :: 3',
Expand Down

0 comments on commit b1d0b98

Please sign in to comment.