-
Notifications
You must be signed in to change notification settings - Fork 116
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* added unit testing framework * added missing newline * moved around files * fixed folder name * added tests * readded fairgbm * clean up * formatting changes * more cleanup * added more tests * updated readme
- Loading branch information
1 parent
10a7d11
commit 12996a4
Showing
42 changed files
with
484 additions
and
140 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 |
---|---|---|
|
@@ -8,6 +8,10 @@ __pycache__/ | |
|
||
.envrc | ||
.manage | ||
.venv | ||
.coverage | ||
.vscode | ||
cov.xml | ||
|
||
*.DS_Store* | ||
|
||
|
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,2 @@ | ||
[pytest] | ||
addopts = --cov=aequitas |
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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
SQLAlchemy>=1.1.1 | ||
tabulate==0.8.2 | ||
xhtml2pdf==0.2.2 | ||
xhtml2pdf==0.2.15 | ||
ohio>=0.2.0 | ||
markdown2==2.3.5 |
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
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,19 @@ | ||
#!/bin/bash | ||
|
||
# Create a virtual environment | ||
python3 -m venv .venv | ||
|
||
# Activate the virtual environment | ||
source .venv/bin/activate | ||
|
||
# Install the required packages | ||
pip install -r ./requirements/main.txt -r ./requirements/cli.txt -r ./requirements/webapp.txt | ||
pip install -e . | ||
|
||
pip install pytest pytest-cov | ||
|
||
# Run the tests | ||
coverage run -m pytest --cov-report xml:cov.xml --cov-report term | ||
|
||
# Deactivate the virtual environment | ||
deactivate |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
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,13 @@ | ||
# Unit Testing in Aequitas | ||
|
||
To run unittests locally, you need to run the following commands from the base folder of the project. | ||
|
||
The below commans only needs to be run once to give the testing script necessary permission to run | ||
|
||
`chmod +x run_tests.sh` | ||
|
||
The testing script itself can be run using the following commans | ||
|
||
`./run_tests.sh` | ||
|
||
The script will run all defined tests in a virtual environment and output the coverage report in the terminal. It will also add an xml file of the coverage report `cov.xml` to the base folder. |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
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,11 @@ | ||
label,sensitive,feature1,feature2 | ||
1,A,0.5,0.1 | ||
0,B,0.2,0.4 | ||
1,C,0.7,0.6 | ||
0,B,0.3,0.8 | ||
1,A,0.9,0.3 | ||
1,A,0.5,0.5 | ||
0,A,0.2,0.2 | ||
1,C,0.7,0.7 | ||
0,B,0.3,0.3 | ||
1,A,0.9,0.9 |
Binary file not shown.
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,2 @@ | ||
label,sensitive,feature1,feature2 | ||
1,A,0.9,0.9 |
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,8 @@ | ||
label,sensitive,feature1,feature2 | ||
1,A,0.5,0.1 | ||
0,B,0.2,0.4 | ||
1,C,0.7,0.6 | ||
0,B,0.3,0.8 | ||
1,A,0.9,0.3 | ||
1,A,0.5,0.5 | ||
0,A,0.2,0.2 |
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 @@ | ||
label,sensitive,feature1,feature2 | ||
1,C,0.7,0.7 | ||
0,B,0.3,0.3 |
Oops, something went wrong.