Skip to content

Fixed some errors introduced before in #PR 44 #150

Fixed some errors introduced before in #PR 44

Fixed some errors introduced before in #PR 44 #150

Workflow file for this run

# This workflow will install Python dependencies, run tests and lint with a single version of Python
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
name: Continuous integration Unit tests
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
PythonBlack:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Check code lints with Black
uses: psf/black@stable
# If the above check failed, post a comment on the PR explaining the failure
- name: Post PR comment
if: failure()
uses: mshick/add-pr-comment@v1
with:
message: |
## Python linting (`black`) is failing
To keep the code consistent with lots of contributors, we run automated code consistency checks.
To fix this CI test, please run:
* Install [`black`](https://black.readthedocs.io/en/stable/): `pip install black`
* Fix formatting errors in your pipeline: `black .`
Once you push these changes the test should pass, and you can hide this comment :+1:
We highly recommend setting up Black in your code editor so that this formatting is done automatically on save. Ask about it on Slack for help!
Thanks again for your contribution!
repo-token: ${{ secrets.GITHUB_TOKEN }}
allow-repeats: false
isort:
runs-on: ubuntu-latest
steps:
- name: Check out source-code repository
uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: python-isort
uses: isort/isort-action@v0.1.0
with:
isortVersion: "latest"
requirementsFiles: "requirements.txt requirements-dev.txt"
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v1
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Install package
run: python setup.py install
- name: Test OpenMS converter
run: |
cd sdrf_pipelines
for sdrf in testdata/*/*.sdrf.tsv
do
pushd $(dirname $sdrf)
python ../../parse_sdrf.py convert-openms -s $(pwd)/../../$sdrf -t2
diff -c experimental_design.tsv expected_experimental_design.tsv >> ../../failures.txt
diff -c expected_openms.tsv openms.tsv >> ../../failures.txt
popd
done
if [ -s failures.txt ]
then
exit 1
fi