Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add functional tests and all tests jobs to ci #9

Open
wants to merge 13 commits into
base: main
Choose a base branch
from
36 changes: 34 additions & 2 deletions .github/workflows/unit_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,43 @@ on:
pull_request:
branches: [ main ]

jobs:
jobs:
run_unit_tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- run: |
cd test/unit
python -m unittest test_utils
python -m unittest test_utils

run_func_tests:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -el {0}
steps:
- uses: actions/checkout@v2
- uses: conda-incubator/setup-miniconda@v2
with:
environment-file: environment.yml
activate-environment: swe4s
- run: |
cd test/func
bash test_search.sh

run_all_tests:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -el {0}
steps:
- uses: actions/checkout@v2
- uses: mamba-org/setup-micromamba@v1
with:
environment-file: environment.yml
environment-name: swe4s
- run: |
cd test/unit
python -m unittest test_utils
cd ../func
bash test_search.sh
6 changes: 6 additions & 0 deletions environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name: swe4s
channels:
- conda-forge
dependencies:
- pycodestyle
- numpy
1 change: 1 addition & 0 deletions search.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
import random
import time
import utils
import numpy as np


def get_args():
Expand Down
Loading