Skip preprocessor step in Actors
[policy/models.git] / models-interactions / model-actors / actor.appc / src / test / java / org / onap / policy / controlloop / actor / appc / ModifyConfigOperationTest.java
index d000038..9c602f5 100644 (file)
@@ -25,6 +25,7 @@ import static org.assertj.core.api.Assertions.assertThatIllegalArgumentException
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertFalse;
 import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertNull;
 import static org.junit.Assert.assertTrue;
 import static org.mockito.ArgumentMatchers.any;
 import static org.mockito.ArgumentMatchers.eq;
@@ -156,6 +157,15 @@ public class ModifyConfigOperationTest extends BasicAppcOperation {
         assertEquals(PolicyResult.SUCCESS, future3.get().getResult());
     }
 
+    /**
+     * Tests startPreprocessorAsync(), when preprocessing is disabled.
+     */
+    @Test
+    public void testStartPreprocessorAsyncDisabled() {
+        params = params.toBuilder().preprocessed(true).build();
+        assertNull(new ModifyConfigOperation(params, config).startPreprocessorAsync());
+    }
+
     @Test
     public void testMakeRequest() throws CoderException {
         AaiCqResponse cq = new AaiCqResponse("{}");