-
Notifications
You must be signed in to change notification settings - Fork 4
38 lines (36 loc) · 1.42 KB
/
main.yml
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
27
28
29
30
31
32
33
34
35
36
37
38
name: Tests
on: [push]
jobs:
test_job:
runs-on: ubuntu-latest
name: A job to run a WAS scan
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Running tests
run: |
echo "Installing app dependencies"
pip install -r requirements.txt
echo "Installing test dependencies"
pip install -r requirements-test.txt
echo "Setting python path"
export PYTHONPATH=.
echo "Running tests"
pytest tests/
- name: Runs the WAS scan
uses: ./
id: was
with:
scan_name: "Test WAS Scan"
wait_for_results: "true"
env:
ACCESS_KEY: ${{ secrets.ACCESS_KEY }}
SECRET_KEY: ${{ secrets.SECRET_KEY }}
- name: Gets the number of low severity findings
run: echo "Number of low severity findings is ${{ steps.was.outputs.number_of_low_severity_findings }}"
- name: Gets the number of medium severity findings
run: echo "Number of medium severity findings is ${{ steps.was.outputs.number_of_medium_severity_findings }}"
- name: Gets the number of high severity findings
run: echo "Number of high severity is ${{ steps.was.outputs.number_of_high_severity_findings }}"
- name: Gets the number of critical severity findings
run: echo "Number of critical severity is ${{ steps.was.outputs.number_of_critical_severity_findings }}"