Skip to content

Commit a2e7258

Browse files
committed
test
1 parent 5a22bb7 commit a2e7258

3 files changed

Lines changed: 28 additions & 4 deletions

File tree

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
package com.codingapi.txlcn.tc;
2+
3+
import org.junit.Test;
4+
import org.junit.runner.RunWith;
5+
import org.springframework.boot.test.context.SpringBootTest;
6+
import org.springframework.test.context.junit4.SpringRunner;
7+
8+
/**
9+
* Description:
10+
* Date: 19-2-20 下午4:24
11+
*
12+
* @author ujued
13+
*/
14+
@RunWith(SpringRunner.class)
15+
@SpringBootTest(classes = {MiniConfiguration.class, TCAutoConfiguration.class})
16+
public class RunTest {
17+
18+
@Test
19+
public void testTxc() throws InterruptedException {
20+
Thread.sleep(10000);
21+
}
22+
}

txlcn-tc/src/test/java/com/codingapi/txlcn/tc/txmsg/RpcTest.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,6 @@ public void testCluster() throws RpcException {
9494
messenger.request(new MessageDto());
9595
}
9696

97-
@Test
98-
public void testTxc() throws InterruptedException {
99-
Thread.sleep(10000);
100-
}
97+
10198

10299
}

txlcn-tm/src/main/java/com/codingapi/txlcn/tm/cluster/TMAutoCluster.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,11 @@ public void init() throws Exception {
108108
}
109109
}
110110

111+
@Override
112+
public void destroy() throws Exception {
113+
fastStorage.removeTMProperties(txManagerConfig.getHost(), txManagerConfig.getPort());
114+
}
115+
111116
@Override
112117
public int order() {
113118
return TxLcnRunnerOrders.MIN;

0 commit comments

Comments
 (0)