diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 0000000000000000000000000000000000000000..5722995c290d06015ed20aae3e71d038abe4ec1e --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,45 @@ +pipeline { + agent any + stages { + stage('Build') { + steps { + echo 'Building...' + sh 'virtualenv --python=/usr/bin/python3 blocnote' + sh """ + source blocnote/bin/activate + pip install -r requirements-dev.txt + pip install -r requirements.txt + """ + } + } + + stage('Test') { + steps { + echo 'Testing...' + sh """ + source blocnote/bin/activate + // python manage.py test + """ + // junit 'tests.xml' + } + } + + stage('Coverage') { + steps { + echo 'Coverage...' + sh """ + source venv/bin/activate + pytest --cov $MODULE $TESTS --cov-report html + """ + publishHTML (target: [ + allowMissing: false, + alwaysLinkToLastBuild: false, + keepAll: true, + reportDir: 'htmlcov', + reportFiles: 'index.html', + reportName: "Coverage" + ]) + } + } + } +} diff --git a/requirements.txt b/requirements.txt index c7936fa20b82b7d3432c28458c000833b2b70403..1ecfef74fdfc380de082c2fab06fb467f41fd42a 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,4 +1,4 @@ Django==1.10.6 psycopg2==2.7 python-decouple==3.0 -git+ssh://git@github.com/Blocp/bpfin.git@v0.1.3 +git+https://bb3dd9a7a6eab87372d5377d65d370738cd25196:x-oauth-basic@github.com/Blocp/bpfin.git@v0.1.3