chore: workaround flaky tests (#651)

Signed-off-by: Andrey Smirnov <smirnov.andrey@gmail.com>
This commit is contained in:
Andrey Smirnov 2019-05-14 01:00:59 +03:00 committed by Andrew Rynhard
parent 42a562a2bc
commit 4bf649f14c
3 changed files with 2 additions and 3 deletions

View File

@ -204,7 +204,6 @@ test: buildkitd
--opt target=$@ \
$(COMMON_ARGS)
@docker load < /tmp/$@.tar
@docker run -i --rm $(DOCKER_TEST_ARGS) autonomy/$@:$(TAG) /bin/test.sh --short
@trap "rm -rf ./.artifacts" EXIT; mkdir -p ./.artifacts && \
docker run -i --rm $(DOCKER_TEST_ARGS) -v $(PWD)/.artifacts:/src/artifacts autonomy/$@:$(TAG) /bin/test.sh && \
cp ./.artifacts/coverage.txt coverage.txt

View File

@ -6,7 +6,7 @@ CGO_ENABLED=1
perform_tests() {
echo "Performing tests"
go test -v -covermode=atomic -coverprofile=artifacts/coverage.txt ./...
go test -v -covermode=atomic -coverprofile=artifacts/coverage.txt -p 4 ./...
}
perform_short_tests() {

View File

@ -107,7 +107,7 @@ func (suite *CheckSuite) TestCheckAbort() {
select {
case <-ctx.Done():
return ctx.Err()
case <-time.After(10 * time.Millisecond):
case <-time.After(25 * time.Millisecond):
return nil
}
}