+ @Test
+ fun `test resolvePropertyDefinitions using sub attributes`() {
+ val bluePrintRuntimeService = getBluePrintRuntimeService()
+
+ bluePrintRuntimeService.setNodeTemplateAttributeValue(
+ "resource-assignment", "assignment-map",
+ JacksonUtils.jsonNode("""
+ {
+ "a-prefix":{
+ "an-object":{
+ "a-key":123
+ }
+ }
+ }
+ """.trimIndent())
+ )
+
+ val propertyDefinitions = mutableMapOf<String, PropertyDefinition>(
+ "resolution" to PropertyDefinition().apply {
+ this.type = "json"
+ this.value = JacksonUtils.jsonNode("""
+ {
+ "get_attribute":[
+ "resource-assignment",
+ "",
+ "assignment-map",
+ "a-prefix",
+ "an-object",
+ "a-key"
+ ]
+ }
+ """.trimIndent())
+ }
+ )
+
+ val result = bluePrintRuntimeService.resolvePropertyDefinitions("workflow", "WORKFLOW", propertyDefinitions)
+
+ assertEquals("123", result["resolution"]!!.asText())
+ }
+