|
| 1 | +<img align="right" style="width: 5em;" src="https://github.com/user-attachments/assets/1e97270f-7925-4cc2-8791-8d0cc77fe512"> |
| 2 | + |
| 3 | + |
| 4 | +# Regression Tests for Altinity ClickHouse Helm Charts |
| 5 | + |
| 6 | +This repository contains comprehensive regression tests for Altinity ClickHouse Helm charts, ensuring proper deployment and configuration of ClickHouse clusters in Kubernetes environments. |
| 7 | + |
| 8 | +## Table of Contents |
| 9 | + |
| 10 | +* [Supported Environment](#supported-environment) |
| 11 | +* [Prerequisites](#prerequisites) |
| 12 | + * [Kubernetes Cluster](#kubernetes-cluster) |
| 13 | + * [Helm](#helm) |
| 14 | + * [Python Modules](#python-modules) |
| 15 | +* [How to Run the Tests](#-how-to-run-the-tests) |
| 16 | +* [Contributing](#contributing) |
| 17 | + |
| 18 | + |
| 19 | +## Supported Environment |
| 20 | + |
| 21 | +- [Ubuntu](https://ubuntu.com/) 22.04 / 24.04 |
| 22 | +- [Python](https://www.python.org/downloads/) >= 3.10.12 |
| 23 | +- [Kubernetes](https://kubernetes.io/) >= 1.24 |
| 24 | +- [Helm](https://helm.sh/) >= 3.8.0 |
| 25 | +- [Minikube](https://minikube.sigs.k8s.io/) >= 1.28.0 (for local testing) |
| 26 | + |
| 27 | +## Prerequisites |
| 28 | + |
| 29 | +To install the necessary prerequisites, follow the instructions below: |
| 30 | + |
| 31 | +### Kubernetes Cluster |
| 32 | + |
| 33 | +You need access to a Kubernetes cluster. For local testing, you can use Minikube: |
| 34 | + |
| 35 | +```bash |
| 36 | +# Install Minikube |
| 37 | +curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-linux-amd64 |
| 38 | +sudo install minikube-linux-amd64 /usr/local/bin/minikube |
| 39 | +``` |
| 40 | + |
| 41 | +### Helm |
| 42 | + |
| 43 | +To install Helm, follow the instructions below: |
| 44 | + |
| 45 | +```bash |
| 46 | +# Install Helm |
| 47 | +curl https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 | bash |
| 48 | + |
| 49 | +# Verify installation |
| 50 | +helm version |
| 51 | +``` |
| 52 | + |
| 53 | +### Python Modules |
| 54 | + |
| 55 | +To install all necessary Python modules, execute the following command: |
| 56 | + |
| 57 | +```bash |
| 58 | +pip3 install -r tests/requirements.txt |
| 59 | +``` |
| 60 | + |
| 61 | +## How to Run the Tests |
| 62 | + |
| 63 | +To run the tests execute the test script: |
| 64 | + |
| 65 | +```bash |
| 66 | +python3 ./tests/run/smoke.py |
| 67 | +``` |
| 68 | + |
| 69 | +## Contributing |
| 70 | + |
| 71 | +When adding new tests: |
| 72 | + |
| 73 | +1. Follow the existing test structure |
| 74 | +2. Add appropriate test steps in the `steps/` directory |
| 75 | +3. Ensure tests are idempotent and clean up after themselves |
| 76 | +4. Add proper error handling and timeouts |
| 77 | + |
0 commit comments