From 2073da6514668ce17e7359900439354fb3432f4e Mon Sep 17 00:00:00 2001 From: sharath reddy Date: Fri, 25 Mar 2022 12:44:19 +0530 Subject: Fixed Sonar Bug and Code Smell Blockers Issue-ID: CLI-439 Signed-off-by: sharath reddy Change-Id: I81bd79661ab7c6b1152fa481d9273a86e77b4f3a Signed-off-by: sharath reddy --- validate/sample-mock-generator/pom.xml | 6 ++++++ .../src/test/java/org/onap/cli/http/mock/MockJsonGeneratorTest.java | 3 ++- 2 files changed, 8 insertions(+), 1 deletion(-) (limited to 'validate/sample-mock-generator') diff --git a/validate/sample-mock-generator/pom.xml b/validate/sample-mock-generator/pom.xml index a61ffb41..db65484b 100644 --- a/validate/sample-mock-generator/pom.xml +++ b/validate/sample-mock-generator/pom.xml @@ -47,6 +47,12 @@ 4.11 test + + org.junit.jupiter + junit-jupiter-api + 5.8.2 + test + org.jmockit jmockit diff --git a/validate/sample-mock-generator/src/test/java/org/onap/cli/http/mock/MockJsonGeneratorTest.java b/validate/sample-mock-generator/src/test/java/org/onap/cli/http/mock/MockJsonGeneratorTest.java index 0e0c0f59..d4697978 100644 --- a/validate/sample-mock-generator/src/test/java/org/onap/cli/http/mock/MockJsonGeneratorTest.java +++ b/validate/sample-mock-generator/src/test/java/org/onap/cli/http/mock/MockJsonGeneratorTest.java @@ -18,6 +18,7 @@ package org.onap.cli.http.mock; import java.io.IOException; import org.junit.Test; +import static org.junit.jupiter.api.Assertions.assertDoesNotThrow; public class MockJsonGeneratorTest { @@ -32,6 +33,6 @@ public class MockJsonGeneratorTest { mockResponse.setStatus(200); mockResponse.setJson("{\"value\" : \"234sdf-345\"}"); - MockJsonGenerator.generateMocking(mockRequest, mockResponse, "target/test"); + assertDoesNotThrow(() -> MockJsonGenerator.generateMocking(mockRequest, mockResponse, "target/test")); } } -- cgit 1.2.3-korg