From 08eedb667efa5cebeade2bb2a64ff2d21597e353 Mon Sep 17 00:00:00 2001 From: Sergey Bronnikov Date: Thu, 31 Mar 2022 11:46:12 +0300 Subject: [PATCH] readme: update section about testing Part of #123 --- Makefile | 27 +++++++++++++++++++++++++-- README.md | 11 ++++------- 2 files changed, 29 insertions(+), 9 deletions(-) diff --git a/Makefile b/Makefile index 72959eeaf..43bf943a4 100644 --- a/Makefile +++ b/Makefile @@ -11,9 +11,32 @@ deps: clean ( cd ./queue; tarantoolctl rocks install queue 1.1.0 ) .PHONY: test -test: +test: test-main test-multi test-queue test-uuid + +.PHONY: test-multi +test-multi: + @echo "Running tests in multiconnection package" + go clean -testcache + go test ./multi/ -v -p 1 + +.PHONY: test-queue +test-queue: + @echo "Running tests in queue package" + cd ./queue/ && tarantool -e "require('queue')" + go clean -testcache + go test ./queue/ -v -p 1 + +.PHONY: test-uuid +test-uuid: + @echo "Running tests in UUID package" + go clean -testcache + go test ./uuid/ -v -p 1 + +.PHONY: test-main +test-main: + @echo "Running tests in main package" go clean -testcache - go test ./... -v -p 1 + go test . -v -p 1 .PHONY: coverage coverage: diff --git a/README.md b/README.md index 7cacfb465..00c9eda79 100644 --- a/README.md +++ b/README.md @@ -187,17 +187,14 @@ make test ``` Tests set up all required `tarantool` processes before run and clean up after. -If you want to run a specific package tests, go to a package folder +If you want to run a specific package tests, call ```bash -cd multi +make test- ``` -and call +For example, for running tests in `multi`, `uuid` and `main` packages, call ```bash -go clean -testcache && go test -v +make test-multi test-uuid test-main ``` -Use the same for main `tarantool` package and `queue` and `uuid` subpackages. -`uuid` tests require -[Tarantool 2.4.1 or newer](https://github.com/tarantool/tarantool/commit/d68fc29246714eee505bc9bbcd84a02de17972c5). ## Alternative connectors