Skip to content

Tests

Tests #398

Workflow file for this run

---
name: Tests
on:
push: {}
pull_request: {}
schedule:
- cron: '0 9 * * *'
workflow_dispatch: {}
jobs:
config:
strategy:
fail-fast: true
matrix:
version:
- 7.7.1
- 7.8.1
- 7.9.3
- 7.10.2
- 7.11.2
- 7.12.1
- 7.13.2
- 7.14.2
- 7.15.2
- 7.16.3
- 7.17.6
- 8.0.1
- 8.1.3
- 8.2.3
- 8.3.3
- 8.4.3
runs-on: ubuntu-latest
container:
image: docker.elastic.co/beats/filebeat:${{ matrix.version }}
options: --user root --entrypoint /bin/bash
steps:
- name: Check Out Repository Code
uses: actions/checkout@v3
- name: Validate Configuration
run: |
cp -v modules.d/exim4.yml.disabled /usr/share/filebeat/modules.d/exim4.yml
cp -Rv module/exim4 /usr/share/filebeat/module
cd /usr/share/filebeat
filebeat test config
filebeat modules list | grep -A 1 'Enabled:' | grep exim4
filebeat run -v --once
tests:
env:
ES_HOST: http://elasticsearch:9200
strategy:
fail-fast: true
matrix:
version:
- 7.7.1
- 7.8.1
- 7.9.3
- 7.10.2
- 7.11.2
- 7.12.1
- 7.13.2
- 7.14.2
- 7.15.2
- 7.16.3
- 7.17.6
- 8.0.1
- 8.1.3
- 8.2.3
- 8.3.3
- 8.4.3
runs-on: ubuntu-latest
container: python:3.10-bullseye
services:
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:${{ matrix.version }}
ports:
- 9200:9200
env:
# Disable security auto configuration for 8.x
# https://www.elastic.co/guide/en/elasticsearch/reference/8.0/configuring-stack-security.html#stack-existing-settings-detected
xpack.security.enabled: false
# Run a single node cluster
discovery.type: single-node
options: --health-cmd "curl http://localhost:9200/_cluster/health" --health-interval 10s --health-timeout 5s --health-retries 5
steps:
- name: Check Cluster Status
run: |
curl --silent ${{ env.ES_HOST }}
curl --silent ${{ env.ES_HOST }}/_cat/health
- name: Check Out Repository Code
uses: actions/checkout@v3
- name: Run Unit Tests
working-directory: tests
run: |
pip3 install deepdiff==5.8.1
python MainPipeline.py --failfast --verbose
python RejectPipeline.py --failfast --verbose