2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2018 Nokia Intellectual Property. All rights reserved.
6 * =============================================================================
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
19 * ============LICENSE_END=========================================================
21 package org.onap.appc.flow.controller.data;
23 import org.junit.Assert;
24 import org.junit.Before;
25 import org.junit.Test;
27 public class ResponseActionTest {
29 private ResponseAction responseAction;
33 responseAction = new ResponseAction();
37 public void get_set_jump() {
38 String jump = "some_jump";
39 responseAction.setJump(jump);
40 Assert.assertEquals(jump, responseAction.getJump());
44 public void get_set_retry() {
45 String retry = "some_retry";
46 responseAction.setRetry(retry);
47 Assert.assertEquals(retry, responseAction.getRetry());
51 public void get_set_wait() {
52 String wait = "some_wait";
53 responseAction.setWait(wait);
54 Assert.assertEquals(wait, responseAction.getWait());
58 public void get_set_intermediate_message() {
59 responseAction.setIntermediateMessage(true);
60 Assert.assertTrue(responseAction.isIntermediateMessage());
64 public void get_set_ignore() {
65 responseAction.setIgnore(true);
66 Assert.assertTrue(responseAction.isIgnore());
70 public void get_set_stop() {
71 responseAction.setStop(true);
72 Assert.assertTrue(responseAction.isStop());
76 public void to_string() {
77 responseAction.setStop(true);
78 responseAction.setIntermediateMessage(true);
79 responseAction.setIgnore(true);
80 responseAction.setJump("some_jump");
81 responseAction.setRetry("some_retry");
82 responseAction.setWait("some_wait");
84 "ResponseAction [wait=some_wait, retry=some_retry, jump=some_jump, ignore=true, stop=true, intermediateMessage=true]",
85 responseAction.toString());