diff options
author | Paul J. Davis <paul.joseph.davis@gmail.com> | 2017-06-30 10:49:38 -0500 |
---|---|---|
committer | Paul J. Davis <paul.joseph.davis@gmail.com> | 2017-06-30 10:49:38 -0500 |
commit | 67048abbd14848c92595a2950b22b20a18607c59 (patch) | |
tree | dd7465c4e11ed3074b385d42f02ad93cfc12df15 | |
parent | 571a2fc0b7445df0f6ad4626f6172bfe6c8c9a7c (diff) | |
download | couchdb-67048abbd14848c92595a2950b22b20a18607c59.tar.gz |
Add a soak-eunit target to Makefile
This allows developers to run eunit in a loop until a test crashes. This
can be helpful for fixing flaky tests that are failing due to timing
related issues. For instance:
make soak-eunit apps=ddoc_cache suites=ddoc_cache_lru_test
This command would run that specific test module repeatedly until it hit
a timing condition that caused a failure. And yes, I used this change to
fix that failure. :D
-rw-r--r-- | Makefile | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -102,6 +102,12 @@ eunit: couch @$(REBAR) setup_eunit 2> /dev/null @$(REBAR) -r eunit $(EUNIT_OPTS) +.PHONY: soak-eunit +soak-eunit: export BUILDDIR = $(shell pwd) +soak-eunit: export ERL_AFLAGS = -config $(shell pwd)/rel/files/eunit.config +soak-eunit: couch + @$(REBAR) setup_eunit 2> /dev/null + while [ $$? -eq 0 ] ; do $(REBAR) -r eunit $(EUNIT_OPTS) ; done .PHONY: javascript # target: javascript - Run JavaScript test suites or specific ones defined by suites option |