From cad78a554e0fed8aa86f49c6990c026e9e93dffb Mon Sep 17 00:00:00 2001 From: Fabian Grutschus Date: Tue, 30 May 2023 08:48:35 +0200 Subject: [PATCH] Added info about tests --- README.md | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/README.md b/README.md index 342a3fe..e721d88 100644 --- a/README.md +++ b/README.md @@ -91,6 +91,32 @@ func main() { } ``` +## Running the tests + +### Unit tests +Running the unit tests: + +```bash +go test -v "./go-zabbix/.." +go test -v "./types/..." +# or: +make unittests +``` + +### Integration tests + +To run the integration tests against a specific Zabbix Server version, you'll need Docker. Then start the containers: + +```bash +export ZBX_VERSION=6.4 +docker compose up -d +# server should be running in a minute +# run tests: +go test -v "./test/integration/..." +# or: +make integration +``` + ## License Released under the [GNU GPL License](https://github.com/fabiang/go-zabbix/blob/master/LICENSE)