Skip to content

Commit d252bb7

Browse files
committed
[FABCJ-214] - Java chaincode gRPC server
clear env variables after connectChaincodeBase() test Signed-off-by: Oleksandr Yamkovyi <[email protected]>
1 parent d48953d commit d252bb7

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

fabric-chaincode-shim/src/test/java/org/hyperledger/fabric/shim/ChaincodeBaseTest.java

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -48,16 +48,6 @@ public class ChaincodeBaseTest {
4848
@Rule
4949
public ExpectedException thrown = ExpectedException.none();
5050

51-
@AfterEach
52-
public void clearEnv() {
53-
environmentVariables.clear("CORE_CHAINCODE_ID_NAME");
54-
environmentVariables.clear("CORE_PEER_ADDRESS");
55-
environmentVariables.clear("CORE_PEER_TLS_ENABLED");
56-
environmentVariables.clear("CORE_PEER_TLS_ROOTCERT_FILE");
57-
environmentVariables.clear("CORE_TLS_CLIENT_KEY_PATH");
58-
environmentVariables.clear("CORE_TLS_CLIENT_CERT_PATH");
59-
}
60-
6151
@Test
6252
public void testNewSuccessResponseEmpty() {
6353
final org.hyperledger.fabric.shim.Chaincode.Response response = ResponseUtils.newSuccessResponse();
@@ -336,6 +326,8 @@ public void onCompleted() {
336326

337327
}
338328
});
329+
330+
environmentVariables.clear("CORE_CHAINCODE_ID_NAME", "CORE_PEER_ADDRESS", "CORE_PEER_TLS_ENABLED");
339331
}
340332

341333
@Test

0 commit comments

Comments
 (0)