-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add basic files * Use environment.yaml and simplify verification script * Add github workflow for conda and pytest * Move config to correct folder * Change env name in ci * Use code from README * Fix SyntaxError * Again * Try different env path * Fix bug * Try again * Add pytest as dependency * Again * Again * Again * Again * Again * Add dummy test * Fix bug * Can I leave that out? * Finalize Tests CI * Rename ci file
- Loading branch information
Showing
3 changed files
with
39 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: Tests | ||
|
||
on: [push, pull_request] | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
|
||
# Checkout the code at the commit (incl. branch) that triggered the workflow | ||
- name: Checkout Repository | ||
uses: actions/checkout@v2 | ||
|
||
# ------------------------------------------------------------------------------------------------------------------ | ||
# Resemble installation section in README.md | ||
- name: Setup Conda Environment | ||
uses: conda-incubator/setup-miniconda@v2 | ||
with: | ||
activate-environment: '.env' | ||
environment-file: 'environment.yaml' | ||
auto-activate-base: false | ||
|
||
- name: Install edugrad | ||
run: | | ||
pip install -e . | ||
# ------------------------------------------------------------------------------------------------------------------ | ||
|
||
- name: Run Tests | ||
# Execute the commands in a bash login shell, ensuring that the shell's environment is fully initialized. | ||
shell: bash -l {0} | ||
run: | | ||
pytest 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 |
---|---|---|
|
@@ -3,3 +3,6 @@ channels: | |
- defaults | ||
dependencies: | ||
- numpy | ||
|
||
# tests | ||
- pytest |
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,3 @@ | ||
|
||
def test_dummy(): | ||
assert True == True |