blob: 94ba98603fa08d54a5ccdbbbc7b8966bae59e43a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
package org.onap.ccsdk.cds.controllerblueprints.core
import org.junit.Test
import kotlin.test.assertEquals
import kotlin.test.assertTrue
class BlueprintErrorTest {
@Test
fun testBlueprintErrorIsCreatedWithemptyList() {
val bluePrintError = BlueprintError()
assertTrue(bluePrintError.allErrors().isEmpty())
}
@Test
fun testAddErrorWith3Params() {
val bluePrintError = BlueprintError()
bluePrintError.addError("type", "name", "error", "step")
assertEquals("type : name : error", bluePrintError.stepErrors("step")!![0])
}
@Test
fun testAddErrorWith2Params() {
val bluePrintError = BlueprintError()
bluePrintError.addError("error", "step")
assertEquals("error", bluePrintError.stepErrors("step")!![0])
}
}
|