Skip to content

Commit

Permalink
Adding CI tests (cloud-bulldozer#59)
Browse files Browse the repository at this point in the history
Signed-off-by: Vishnu Challa <[email protected]>
Co-authored-by: Vishnu Challa <[email protected]>
  • Loading branch information
2 people authored and jtaleric committed Sep 13, 2024
1 parent c8a751e commit 116ed1c
Show file tree
Hide file tree
Showing 23 changed files with 254 additions and 66 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/builders.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Builders
on:
workflow_call:
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.11"]
steps:
- uses: actions/checkout@v3

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}

- name: build and install
run: |
pip install .
23 changes: 23 additions & 0 deletions .github/workflows/ci-tests.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: CI tests
on:
push:
branches:
- master
- main
pull_request:
branches:
- master
- main

jobs:
lint:
uses: ./.github/workflows/pylint.yaml

build:
uses: ./.github/workflows/builders.yaml

tests:
needs: build
uses: ./.github/workflows/tests.yaml
secrets: inherit

Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
name: Build and Push Image
on: [ push ]
name: Image Push
on:
push:
branches:
- master
- main

jobs:
build:
name: Build and push image
name: Image Push
runs-on: ubuntu-20.04

steps:
Expand Down
11 changes: 6 additions & 5 deletions .github/workflows/pylint.yml → .github/workflows/pylint.yaml
Original file line number Diff line number Diff line change
@@ -1,25 +1,26 @@
name: Pylint

on: [push,pull_request]

on:
workflow_call:
jobs:
build:
lint:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.11"]
steps:
- uses: actions/checkout@v3

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pylint
pip install -r requirements.txt
pip install .
- name: Analysing the code with pylint
run: |
pylint -d C0103 -d R0912 $(git ls-files '*/*.py' '*.py')
45 changes: 45 additions & 0 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: Execute tests
on:
workflow_call:
jobs:
tests:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.11"]
steps:

- name: Install bats
uses: bats-core/[email protected]
with:
bats-version: 1.10.0
support-install: false
assert-install: false
detik-install: false
file-install: false

- name: Check out code
uses: actions/checkout@v3
with:
fetch-depth: 1
ref: ${{ github.event.pull_request.head.sha }}
persist-credentials: false

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pylint
pip install -r requirements.txt
pip install .
- name: Execute Tests
run: |
bats -F pretty -T --print-output-on-failure test.bats
env:
TERM: linux
QE_ES_SERVER: ${{ secrets.QE_ES_SERVER }}
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions examples/label-small-scale-cluster-density.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
tests :
- name : small-scale-cluster-density-v2
index: ospst-perf-scale-ci-*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
platform: AWS
masterNodesType: m6a.xlarge
Expand Down
8 changes: 4 additions & 4 deletions examples/payload-scale-415.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
tests :
- name : aws-small-scale-cluster-density-v2
index: ospst-perf-scale-ci-*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
platform: AWS
clusterType: self-managed
Expand Down Expand Up @@ -52,8 +52,8 @@ tests :
value: duration
agg_type: avg
- name : aws-payload-scale-node-density
index: ospst-perf-scale-ci-*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
platform: AWS
clusterType: self-managed
Expand Down
8 changes: 4 additions & 4 deletions examples/payload-scale-416.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
tests :
- name : aws-small-scale-cluster-density-v2
index: ospst-perf-scale-ci-*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
platform: AWS
clusterType: self-managed
Expand Down Expand Up @@ -52,8 +52,8 @@ tests :
value: duration
agg_type: avg
- name : aws-payload-scale-node-density
index: ospst-perf-scale-ci-*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
platform: AWS
clusterType: self-managed
Expand Down
28 changes: 14 additions & 14 deletions examples/readout-control-plane-cdv2.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
tests :
- name : cluster-density-v2-24nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -37,8 +37,8 @@ tests :
agg_type: avg

- name : cluster-density-v2-120nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -74,8 +74,8 @@ tests :
agg_type: avg

- name : cluster-density-v2-249nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -111,8 +111,8 @@ tests :
agg_type: avg

- name : cdv2-kube-apiserver-etcd-249nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -160,8 +160,8 @@ tests :
agg_type: avg

- name : cd-v2-controller-manager-249nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -204,8 +204,8 @@ tests :
agg_type: avg

- name : cd-v2-api-request-latency-249nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -249,8 +249,8 @@ tests :
agg_type: avg

- name : cd-v2-etcd-latency-249nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down
28 changes: 14 additions & 14 deletions examples/readout-control-plane-node-density.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
tests :
- name : node-density-heavy-24nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -49,8 +49,8 @@ tests :
agg_type: avg

- name : node-density-24nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -81,8 +81,8 @@ tests :
agg_type: avg

- name : node-density-120nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -113,8 +113,8 @@ tests :
agg_type: avg

- name : node-density-249nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -145,8 +145,8 @@ tests :
agg_type: avg

- name : node-density-cni-24nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -177,8 +177,8 @@ tests :
agg_type: avg

- name : node-density-cni-120nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down Expand Up @@ -209,8 +209,8 @@ tests :
agg_type: avg

- name : node-density-cni-249nodes
index: ospst-perf-scale-ci*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down
2 changes: 2 additions & 0 deletions examples/readout-netperf-tcp.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
tests :
- name : k8s-netperf-tcp
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
ocpVersion: 4.15
platform: AWS
Expand Down
4 changes: 2 additions & 2 deletions examples/small-scale-cluster-density.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
tests :
- name : aws-small-scale-cluster-density-v2
index: ospst-perf-scale-ci-*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
platform: AWS
masterNodesType: m6a.xlarge
Expand Down
4 changes: 2 additions & 2 deletions examples/small-scale-node-density-cni.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
tests :
- name : aws-small-scale-node-density-cni
index: ospst-perf-scale-ci-*
benchmarkIndex: ospst-ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
platform: AWS
masterNodesType: m6a.xlarge
Expand Down
4 changes: 2 additions & 2 deletions examples/trt-external-payload-cluster-density.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
tests :
- name : payload-cluster-density-v2
index: perf_scale_ci-*
benchmarkIndex: ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
platform: AWS
clusterType: self-managed
Expand Down
4 changes: 2 additions & 2 deletions examples/trt-external-payload-crd-scale.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
tests :
- name : payload-crd-scale
index: perf_scale_ci-*
benchmarkIndex: ripsaw-kube-burner*
index: {{ es_metadata_index }}
benchmarkIndex: {{ es_benchmark_index }}
metadata:
platform: AWS
clusterType: self-managed
Expand Down
Loading

0 comments on commit 116ed1c

Please sign in to comment.