Skip to content

Commit

Permalink
Merge pull request #183 from Mrgove10/githubactions
Browse files Browse the repository at this point in the history
Github actions
  • Loading branch information
zerasul committed Oct 9, 2020
2 parents 5111d63 + 3e84511 commit 0a51022
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: blask Build
on:
push:
branches:
- master
- githubactions

env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}

jobs:
test:
runs-on: ubuntu-latest

steps:
- name: Clone repo
uses: actions/checkout@v2

- name: Setup python 3.6
uses: actions/setup-python@v2
with:
python-version: '3.6' # Version range or exact version of a Python version to use, using SemVer's version range syntax
architecture: 'x64' # optional x64 or x86. Defaults to x64 if not specified

- name: Setup sonarqube
uses: warchant/setup-sonar-scanner@v1

- name: pip install
run : |
pip install -r requirements.txt
pip install pylint
- name: Code coverage
run : export PYTHONPATH=$PYTHONPATH:$(pwd) && pytest --cov=Blask --cov-report=xml && pylint Blask --exit-zero

- name: Sonar cube
run: sonar-scanner -Dsonar.login=$SONAR_TOKEN -Dsonar.projectKey=blask-project-key -Dsonar.sources=Blask/ -Dsonar.organization=zerasul-github -Dsonar.python.coverage.reportPaths=coverage.xml -Dsonar.projectName=Blask

0 comments on commit 0a51022

Please sign in to comment.