Skip to content

Commit

Permalink
For alibaba#5976. fail CI directly if UT can't pass.
Browse files Browse the repository at this point in the history
For alibaba#5976. fail CI directly if UT can't pass.

For alibaba#5976. fail CI directly if UT can't pass.
  • Loading branch information
KomachiSion committed Jun 18, 2021
1 parent 7c30acc commit 4e475ab
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 34 deletions.
6 changes: 2 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
java: [8, 11]
java: [8]
steps:
- name: Cache Maven Repos
uses: actions/cache@v2
Expand All @@ -26,11 +26,9 @@ jobs:
${{ runner.os }}-maven-
- uses: actions/checkout@v2
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@v2
uses: actions/setup-java@v1
with:
java-version: ${{ matrix.java }}
distribution: 'adopt'
architecture: x64
- name: Check with Maven
run: mvn -B clean package apache-rat:check findbugs:findbugs -Dmaven.test.skip=true
- name: Build with Maven
Expand Down
23 changes: 0 additions & 23 deletions .github/workflows/maven.yml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ public void testGetter() {
Assert.assertEquals(0, cacheData1.getTaskId());
Assert.assertFalse(cacheData1.isSyncWithServer());
Assert.assertFalse(cacheData1.isUseLocalConfigInfo());
Assert.assertEquals(0, cacheData1.getLastModifiedTs());
Assert.assertEquals(0, cacheData1.getLastModifiedTs().intValue());
Assert.assertEquals(0, cacheData1.getLocalConfigInfoVersion());

cacheData1.setInitializing(false);
Expand All @@ -76,7 +76,7 @@ public void testGetter() {
//TODO FIX getType
// Assert.assertFalse("123",cacheData1.getType());
Assert.assertTrue(cacheData1.isUseLocalConfigInfo());
Assert.assertEquals(timeStamp, cacheData1.getLastModifiedTs());
Assert.assertEquals(timeStamp, cacheData1.getLastModifiedTs().longValue());
Assert.assertEquals(timeStamp, cacheData1.getLocalConfigInfoVersion());
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ private File getRuleFile(String pointName) {
private File checkBaseDir() {
File baseDir = new File(EnvUtil.getNacosHome(), "data" + File.separator + "tps" + File.separator);
if (!baseDir.exists()) {
baseDir.mkdir();
baseDir.mkdirs();
}
return baseDir;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,11 @@

public class TpsMonitorManagerTest {

static TpsMonitorManager tpsMonitorManager = new TpsMonitorManager();
static TpsMonitorManager tpsMonitorManager;

@BeforeClass
public static void setUpBeforeClass() {
tpsMonitorManager = new TpsMonitorManager();
TpsMonitorPoint publish = new TpsMonitorPoint("configPublish");
tpsMonitorManager.registerTpsControlPoint(publish);
TpsControlRule rule = new TpsControlRule();
Expand Down
3 changes: 0 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -412,9 +412,6 @@
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<version>${maven-surefire-plugin.version}</version>
<configuration>
<testFailureIgnore>true</testFailureIgnore>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
Expand Down

0 comments on commit 4e475ab

Please sign in to comment.