nifi-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mcgil...@apache.org
Subject nifi git commit: NIFI-4538: - Fixing broken unit test.
Date Tue, 20 Feb 2018 22:15:12 GMT
Repository: nifi
Updated Branches:
  refs/heads/master ba9e72ed8 -> 160bea8bf


NIFI-4538:
- Fixing broken unit test.


Project: http://git-wip-us.apache.org/repos/asf/nifi/repo
Commit: http://git-wip-us.apache.org/repos/asf/nifi/commit/160bea8b
Tree: http://git-wip-us.apache.org/repos/asf/nifi/tree/160bea8b
Diff: http://git-wip-us.apache.org/repos/asf/nifi/diff/160bea8b

Branch: refs/heads/master
Commit: 160bea8bf3020d4a76b5519d553e35bb017dbf89
Parents: ba9e72e
Author: Matt Gilman <matt.c.gilman@gmail.com>
Authored: Tue Feb 20 17:14:49 2018 -0500
Committer: Matt Gilman <matt.c.gilman@gmail.com>
Committed: Tue Feb 20 17:14:49 2018 -0500

----------------------------------------------------------------------
 .../apache/nifi/web/controller/ControllerSearchServiceTest.java   | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/nifi/blob/160bea8b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/test/java/org/apache/nifi/web/controller/ControllerSearchServiceTest.java
----------------------------------------------------------------------
diff --git a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/test/java/org/apache/nifi/web/controller/ControllerSearchServiceTest.java
b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/test/java/org/apache/nifi/web/controller/ControllerSearchServiceTest.java
index 5b8666f..19af829 100644
--- a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/test/java/org/apache/nifi/web/controller/ControllerSearchServiceTest.java
+++ b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/test/java/org/apache/nifi/web/controller/ControllerSearchServiceTest.java
@@ -33,6 +33,7 @@ import org.junit.Test;
 import org.mockito.Mockito;
 
 import java.util.HashSet;
+import java.util.Optional;
 
 import static org.junit.Assert.assertTrue;
 import static org.mockito.Matchers.any;
@@ -354,6 +355,7 @@ public class ControllerSearchServiceTest {
         Mockito.doReturn(processor1).when(processorNode1).getProcessor();
         // set processor node's attributes
         Mockito.doReturn(processorId).when(processorNode1).getIdentifier();
+        Mockito.doReturn(Optional.ofNullable(null)).when(processorNode1).getVersionedComponentId();
// not actually searching based on versioned component id
         Mockito.doReturn(processorName).when(processorNode1).getName();
 
         // assign processor node to its PG
@@ -380,6 +382,7 @@ public class ControllerSearchServiceTest {
         final ProcessGroup processGroup = mock(ProcessGroup.class);
 
         Mockito.doReturn(processGroupId).when(processGroup).getIdentifier();
+        Mockito.doReturn(Optional.ofNullable(null)).when(processGroup).getVersionedComponentId();
// not actually searching based on versioned component id
         Mockito.doReturn(processGroupName).when(processGroup).getName();
         Mockito.doReturn(parent).when(processGroup).getParent();
         Mockito.doReturn(versionControlInformation).when(processGroup).getVersionControlInformation();


Mime
View raw message