parent
fba50dee1e
commit
5f339ab312
2 changed files with 12 additions and 11 deletions
|
@ -1,10 +1,10 @@
|
|||
name: Hub-CI
|
||||
name: Basic functionals tests
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ functional_basic_tests ]
|
||||
branches: [ master ]
|
||||
pull_request:
|
||||
branches: [ functional_basic_tests ]
|
||||
branches: [ master ]
|
||||
|
||||
jobs:
|
||||
build:
|
|
@ -1,4 +1,4 @@
|
|||
name: Hub-CI
|
||||
name: Hub tests
|
||||
|
||||
on:
|
||||
push:
|
||||
|
@ -33,26 +33,27 @@ jobs:
|
|||
git clone https://github.com/crowdsecurity/hub-tests.git
|
||||
cd hub-tests
|
||||
make
|
||||
- uses: oprypin/find-latest-tag@v1
|
||||
- id: keydb
|
||||
uses: pozetroninc/github-action-get-latest-release@master
|
||||
with:
|
||||
repository: crowdsecurity/crowdsec # The repository to scan.
|
||||
releases-only: true # We know that all relevant tags have a GitHub release for them.
|
||||
id: crowdsec # The step ID to refer to later.
|
||||
owner: crowdsecurity
|
||||
repo: crowdsec
|
||||
excludes: prerelease, draft
|
||||
- name: Create crowdsec test env with all parsers from the release
|
||||
run: |
|
||||
cd crowdsec-${{ steps.crowdsec.outputs.tag }}
|
||||
cd crowdsec-${{ steps.keydb.outputs.release }}
|
||||
./test_env.sh
|
||||
cd tests
|
||||
for i in `./cscli -c dev.yaml list parsers -a -o json | jq -r ".[].name" ` ; do
|
||||
./cscli -c dev.yaml install parser $i ;
|
||||
done
|
||||
- name: Setup hub ci in crowdsec
|
||||
working-directory: ./crowdsec-${{ steps.crowdsec.outputs.tag }}/tests/
|
||||
working-directory: ./crowdsec-${{ steps.keydb.outputs.release }}/tests/
|
||||
run: |
|
||||
cp -R ../../hub-tests/tests .
|
||||
cp ../../hub-tests/main .
|
||||
- name: Run the HUB CI
|
||||
working-directory: ./crowdsec-${{ steps.crowdsec.outputs.tag }}/tests/
|
||||
working-directory: ./crowdsec-${{ steps.keydb.outputs.release }}/tests/
|
||||
run: |
|
||||
for i in `find ./tests -mindepth 1 -maxdepth 1 -type d` ; do
|
||||
echo "::group::Test-${i}" ;
|
Loading…
Reference in a new issue