Migrate mdsal-common-api to JUnit5
[mdsal.git] / common / mdsal-common-api / src / test / java / org / opendaylight / mdsal / common / api / EmptyCommitInfoTest.java
diff --git a/common/mdsal-common-api/src/test/java/org/opendaylight/mdsal/common/api/EmptyCommitInfoTest.java b/common/mdsal-common-api/src/test/java/org/opendaylight/mdsal/common/api/EmptyCommitInfoTest.java
new file mode 100644 (file)
index 0000000..43546e8
--- /dev/null
@@ -0,0 +1,23 @@
+/*
+ * Copyright (c) 2023 PANTHEON.tech, s.r.o. and others.  All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.mdsal.common.api;
+
+import static org.junit.jupiter.api.Assertions.assertSame;
+import static org.junit.jupiter.api.Assertions.assertTrue;
+
+import com.google.common.util.concurrent.Futures;
+import org.junit.jupiter.api.Test;
+
+class EmptyCommitInfoTest {
+    @Test
+    void testFuture() throws Exception {
+        final var future = EmptyCommitInfo.FLUENT_INSTANCE;
+        assertTrue(future.isDone());
+        assertSame(EmptyCommitInfo.INSTANCE, Futures.getDone(future));
+    }
+}