Run rabbit_ct_hook before cth_styledout, so that default logger handler properly removed
As a follow-up to my GChat thread about removing default logger handler to clean CT stdout, I was looking at injecting logger config with undefined default handler to ct_run. It is possible but breaks cth_styledout - no nice green things whatsoever. Then I found rabbit_ct_hook which calls redirect_logger_to_ct_logs which in turn calls logger:remove_handler(default) apparently with zero effect! To cut story short - turned out rabbit_ct_hook must run before cth_styledout for remove_handler line to have any effect
This commit is contained in:
parent
b527fc31ed
commit
77477dee6e
|
@ -151,6 +151,7 @@ MANPAGES = $(wildcard $(DOCS_DIR)/*.[0-9])
|
|||
WEB_MANPAGES = $(patsubst %,%.html,$(MANPAGES))
|
||||
MD_MANPAGES = $(patsubst %,%.md,$(MANPAGES))
|
||||
|
||||
CT_HOOKS = rabbit_ct_hook
|
||||
DEP_EARLY_PLUGINS = rabbit_common/mk/rabbitmq-early-plugin.mk
|
||||
DEP_PLUGINS = rabbit_common/mk/rabbitmq-plugin.mk
|
||||
|
||||
|
@ -221,8 +222,6 @@ ct-fast:
|
|||
ct-slow:
|
||||
$(MAKE) ct CT_SUITES='$(SLOW_CT_SUITES)'
|
||||
|
||||
CT_OPTS += -ct_hooks rabbit_ct_hook []
|
||||
|
||||
# Parallel CT.
|
||||
#
|
||||
# @todo We must ensure that the CT_OPTS also apply to ct-master
|
||||
|
|
|
@ -38,7 +38,7 @@ CT_OPTS += -kernel net_ticktime 5
|
|||
# This hook will change the output of common_test to something more
|
||||
# concise and colored.
|
||||
|
||||
CT_HOOKS ?= cth_styledout
|
||||
CT_HOOKS += cth_styledout
|
||||
TEST_DEPS += cth_styledout
|
||||
|
||||
ifdef CONCOURSE
|
||||
|
|
Loading…
Reference in New Issue