-
-
Notifications
You must be signed in to change notification settings - Fork 33
Expand file tree
/
Copy pathcodecov_push.sh
More file actions
executable file
·26 lines (19 loc) · 862 Bytes
/
codecov_push.sh
File metadata and controls
executable file
·26 lines (19 loc) · 862 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/sh
# To run using ZSH: zsh -i ./codecov_push.sh
# To run using bash: bash -i ./codecov_push.sh
# We do test on Python 3.11 (latest Python version)
# Create a new Python env for Deepparse tests and activate it
conda create --name deepparse_pytest_3_11 python=3.11 -y --force
conda activate deepparse_pytest_3_11
# Install dependencies
pip install -Ur tests/requirements.txt
pip install -Ur requirements.txt
# Run pytest from conda env
echo "*****Running test in Conda*****"
# --live-stream is to remove the Conda capture of the stream
conda run -n deepparse_pytest_3_11 --live-stream pytest --cov ./deepparse --cov-report html --cov-report xml --cov-config=.coveragerc
# Push the coverage file
./codecov -f coverage.xml -n unittest-integrationtest -t $CODECOVKEYDEEPPARSE
# close conda env
conda deactivate
conda env remove -n deepparse_pytest_3_11