This is an automated email from the ASF dual-hosted git repository. spmallette pushed a commit to branch travis-fix in repository https://gitbox.apache.org/repos/asf/tinkerpop.git
commit ee616c4aae50d3758d9bb88cb0240e03a196842e Author: Stephen Mallette <[email protected]> AuthorDate: Tue Apr 27 07:08:57 2021 -0400 Turn on start/end logging for individual tests. When travis hangs on server integration tests it's helpful to know which one was the one causing the problem. CTR --- .../AbstractGremlinServerIntegrationTest.java | 26 +++++++++------------- .../src/test/resources/log4j-test.properties | 1 + 2 files changed, 11 insertions(+), 16 deletions(-) diff --git a/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/server/AbstractGremlinServerIntegrationTest.java b/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/server/AbstractGremlinServerIntegrationTest.java index c443d6d..e527b1f 100644 --- a/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/server/AbstractGremlinServerIntegrationTest.java +++ b/gremlin-server/src/test/java/org/apache/tinkerpop/gremlin/server/AbstractGremlinServerIntegrationTest.java @@ -18,14 +18,9 @@ */ package org.apache.tinkerpop.gremlin.server; -import org.apache.tinkerpop.gremlin.server.channel.HttpChannelizerIntegrateTest; import org.apache.tinkerpop.gremlin.server.channel.UnifiedChannelizer; import org.apache.tinkerpop.gremlin.server.channel.UnifiedChannelizerIntegrateTest; -import org.apache.tinkerpop.gremlin.server.channel.WebSocketChannelizer; -import org.apache.tinkerpop.gremlin.server.channel.WebSocketChannelizerIntegrateTest; import org.apache.tinkerpop.gremlin.server.op.OpLoader; -import org.apache.tinkerpop.gremlin.server.op.session.SessionOpProcessor; -import org.apache.tinkerpop.gremlin.server.op.standard.StandardOpProcessor; import org.junit.After; import org.junit.Before; import org.junit.Rule; @@ -90,26 +85,17 @@ public abstract class AbstractGremlinServerIntegrationTest { @Before public void setUp() throws Exception { - logger.info("* Testing: " + name.getMethodName()); - logger.info("* Epoll option enabled:" + GREMLIN_SERVER_EPOLL); + logger.info("Starting: " + name.getMethodName()); startServer(); } public void setUp(final Settings settings) throws Exception { - logger.info("* Testing: " + name.getMethodName()); - logger.info("* Epoll option enabled:" + GREMLIN_SERVER_EPOLL); + logger.info("Starting: " + name.getMethodName()); startServer(settings); } - private boolean shouldTestUnified() { - // ignore all tests in the UnifiedChannelizerIntegrateTest package as they are already rigged to test - // over the various channelizer implementations - return Boolean.parseBoolean(System.getProperty("testUnified", "false")) && - !this.getClass().getPackage().equals(UnifiedChannelizerIntegrateTest.class.getPackage()); - } - public void startServer(final Settings settings) throws Exception { if (null == settings) { startServer(); @@ -150,6 +136,7 @@ public abstract class AbstractGremlinServerIntegrationTest { @After public void tearDown() throws Exception { stopServer(); + logger.info("Ending: " + name.getMethodName()); } public void stopServer() throws Exception { @@ -193,4 +180,11 @@ public abstract class AbstractGremlinServerIntegrationTest { } assumeThat("Neo4j implementation was not included for testing - run with -DincludeNeo4j", neo4jIncludedForTesting, is(true)); } + + private boolean shouldTestUnified() { + // ignore all tests in the UnifiedChannelizerIntegrateTest package as they are already rigged to test + // over the various channelizer implementations + return Boolean.parseBoolean(System.getProperty("testUnified", "false")) && + !this.getClass().getPackage().equals(UnifiedChannelizerIntegrateTest.class.getPackage()); + } } diff --git a/gremlin-server/src/test/resources/log4j-test.properties b/gremlin-server/src/test/resources/log4j-test.properties index 9b8ed83..4485712 100644 --- a/gremlin-server/src/test/resources/log4j-test.properties +++ b/gremlin-server/src/test/resources/log4j-test.properties @@ -21,6 +21,7 @@ log4j.appender.stdout.layout=org.apache.log4j.PatternLayout log4j.appender.stdout.layout.ConversionPattern=[%p] %C - %m%n log4j.logger.org.apache.tinkerpop.gremlin.server.AbstractChannelizer=ERROR +log4j.logger.org.apache.tinkerpop.gremlin.server.AbstractGremlinServerIntegrationTest=INFO log4j.logger.org.apache.tinkerpop.gremlin.server.op.AbstractEvalOpProcessor=ERROR log4j.logger.org.apache.tinkerpop.gremlin.server.handler.MultiTaskSession=ERROR log4j.logger.org.apache.tinkerpop.gremlin.server.handler.SingleTaskSession=ERROR
