Removed redundant timeout handling for executeCommand
[ccsdk/cds.git] / ms / blueprintsprocessor / modules / blueprints / blueprint-core / src / test / kotlin / org / onap / ccsdk / cds / controllerblueprints / core / BlueprintErrorTest.kt
1 package org.onap.ccsdk.cds.controllerblueprints.core
2
3 import org.junit.Test
4 import kotlin.test.assertEquals
5 import kotlin.test.assertTrue
6
7 class BlueprintErrorTest {
8
9     @Test
10     fun testBlueprintErrorIsCreatedWithemptyList() {
11         val bluePrintError = BlueprintError()
12
13         assertTrue(bluePrintError.allErrors().isEmpty())
14     }
15
16     @Test
17     fun testAddErrorWith3Params() {
18         val bluePrintError = BlueprintError()
19
20         bluePrintError.addError("type", "name", "error", "step")
21
22         assertEquals("type : name : error", bluePrintError.stepErrors("step")!![0])
23     }
24
25     @Test
26     fun testAddErrorWith2Params() {
27         val bluePrintError = BlueprintError()
28
29         bluePrintError.addError("error", "step")
30
31         assertEquals("error", bluePrintError.stepErrors("step")!![0])
32     }
33 }