From 93d2eb674b094ee4feee0ef1e46096098c5a22b4 Mon Sep 17 00:00:00 2001 From: Jerrick Zhu Date: Wed, 15 Aug 2018 20:46:38 +0800 Subject: [PATCH] fix ut stable, #2227 (#2302) * fix ut, #2227 * add cache for travis ci * fix travis problem, skip javadoc --- .travis.yml | 9 ++++++++- .../com/alibaba/dubbo/config/RegistryConfigTest.java | 1 + 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 529e7ff0477..d928330aa4e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -6,8 +6,15 @@ jdk: - oraclejdk8 - openjdk7 +cache: + directories: + - '$HOME/.m2/repository' + +install: + - ./mvnw clean install -DskipTests=true -Dcheckstyle.skip=false -Drat.skip=false -Dmaven.javadoc.skip=true + script: - - travis_wait 30 ./mvnw clean package + - travis_wait 30 ./mvnw test after_success: - bash <(curl -s https://codecov.io/bash) diff --git a/dubbo-config/dubbo-config-api/src/test/java/com/alibaba/dubbo/config/RegistryConfigTest.java b/dubbo-config/dubbo-config-api/src/test/java/com/alibaba/dubbo/config/RegistryConfigTest.java index 1d9bbe2038f..086a4fa589f 100644 --- a/dubbo-config/dubbo-config-api/src/test/java/com/alibaba/dubbo/config/RegistryConfigTest.java +++ b/dubbo-config/dubbo-config-api/src/test/java/com/alibaba/dubbo/config/RegistryConfigTest.java @@ -69,6 +69,7 @@ public void testWait() throws Exception { registry.setWait(10); assertThat(registry.getWait(), is(10)); assertThat(System.getProperty(Constants.SHUTDOWN_WAIT_KEY), equalTo("10")); + System.clearProperty(Constants.SHUTDOWN_WAIT_KEY); } @Test