Skip to content

Fixed pre-commit erros #77

Fixed pre-commit erros

Fixed pre-commit erros #77

Workflow file for this run

name: BioNeuralNet CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ["3.10", "3.11"]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
check-latest: true
- name: Cache pip dependencies
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt', '**/requirements-dev.txt') }}
restore-keys: ${{ runner.os }}-pip-
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
pip install -r requirements-dev.txt
pip install torch
pip install torch_geometric
shell: bash
- name: Install R
uses: r-lib/actions/setup-r@v2
with:
r-version: "latest"
- name: Install R packages
run: |
Rscript -e "if (!requireNamespace('BiocManager', quietly = TRUE)) install.packages('BiocManager', repos='https://cran.r-project.org')"
Rscript -e "install.packages(c('dplyr', 'jsonlite'), repos='https://cran.r-project.org')"
Rscript -e "BiocManager::install(c('impute', 'preprocessCore', 'GO.db', 'AnnotationDbi'), update=FALSE, ask=FALSE)"
Rscript -e "install.packages('SmCCNet', repos='https://cran.r-project.org')"
Rscript -e "install.packages('WGCNA', repos='https://cran.r-project.org')"
shell: bash
- name: Run tests with pytest
run: |
find . -name ".coverage*" -delete
pytest --cov=bioneuralnet --cov-report=xml tests/
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.xml
flags: unittests
name: codecov-umbrella