snikhil5 commented on code in PR #3479:
URL: https://github.com/apache/storm/pull/3479#discussion_r885711253
##########
storm-server/src/test/java/org/apache/storm/TickTupleTest.java:
##########
@@ -93,7 +92,7 @@ public void testTickTupleWorksWithSystemBolt() throws
Exception {
} catch (ConditionTimeoutException e) {
throw new AssertionError(e.getMessage());
}
- assertNull("The bolt got a tuple that is not a tick tuple " +
nonTickTuple.get(), nonTickTuple.get());
+ assertNull(nonTickTuple.get(), "The bolt got a tuple that is
not a tick tuple " + nonTickTuple.get());
Review Comment:
we don't need to negate here ..
##########
storm-server/src/test/java/org/apache/storm/blobstore/LocalFsBlobStoreSynchronizerTest.java:
##########
@@ -30,51 +30,46 @@
import
org.apache.storm.shade.org.apache.curator.framework.CuratorFrameworkFactory;
import org.apache.storm.shade.org.apache.curator.retry.ExponentialBackoffRetry;
import org.apache.storm.utils.Utils;
-import org.apache.zookeeper.server.NIOServerCnxnFactory;
-import org.junit.After;
-import org.junit.Before;
-import org.junit.Test;
+import org.junit.jupiter.api.AfterEach;
+import org.junit.jupiter.api.BeforeAll;
+import org.junit.jupiter.api.BeforeEach;
+import org.junit.jupiter.api.Test;
-import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertTrue;
+import static org.junit.jupiter.api.Assertions.assertEquals;
+import static org.junit.jupiter.api.Assertions.assertTrue;
/**
* Unit tests for most of the testable utility methods
* and LocalFsBlobStoreSynchronizer class methods
*/
public class LocalFsBlobStoreSynchronizerTest {
- private URI base;
- private File baseFile;
- private static Map<String, Object> conf = new HashMap();
- private NIOServerCnxnFactory factory;
+ private static Map<String, Object> conf = new HashMap<>();
+
+ private File baseFile;
Review Comment:
ok
##########
storm-server/src/test/java/org/apache/storm/container/oci/OciUtilsTest.java:
##########
@@ -117,22 +126,22 @@ public void adjustImageConfigForTopoTest() throws
InvalidTopologyException {
//case 3: configs are set properly; nothing will happen
topoConf.put(Config.TOPOLOGY_OCI_IMAGE, image1);
OciUtils.adjustImageConfigForTopo(conf, topoConf, topoId);
- Assert.assertEquals(image1, topoConf.get(Config.TOPOLOGY_OCI_IMAGE));
+ assertEquals(image1, topoConf.get(Config.TOPOLOGY_OCI_IMAGE));
//case 4: topology oci image is not set; will be set to default image
topoConf.remove(Config.TOPOLOGY_OCI_IMAGE);
OciUtils.adjustImageConfigForTopo(conf, topoConf, topoId);
- Assert.assertEquals(defaultImage,
topoConf.get(Config.TOPOLOGY_OCI_IMAGE));
+ assertEquals(defaultImage, topoConf.get(Config.TOPOLOGY_OCI_IMAGE));
//case 5: any topology oci image is allowed
allowedImages.add("*");
String image2 = "storm/rhel7:dev_wow";
topoConf.put(Config.TOPOLOGY_OCI_IMAGE, image2);
OciUtils.adjustImageConfigForTopo(conf, topoConf, topoId);
- Assert.assertEquals(image2, topoConf.get(Config.TOPOLOGY_OCI_IMAGE));
+ assertEquals(image2, topoConf.get(Config.TOPOLOGY_OCI_IMAGE));
}
- @Test(expected = WrappedInvalidTopologyException.class)
+ @Test
public void adjustImageConfigForTopoNotInAllowedList() throws
InvalidTopologyException {
Review Comment:
done
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]