diff --git a/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/utils/ConfigUtilsTest.scala b/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/utils/ConfigUtilsTest.scala index ace12785cea4858f5e9b3e57e12174fbf9d502bf..4dbb1daec6a9b9b5f460cb6b64bd25ce5d7c9f38 100644 --- a/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/utils/ConfigUtilsTest.scala +++ b/public/biopet-framework/src/test/scala/nl/lumc/sasc/biopet/utils/ConfigUtilsTest.scala @@ -214,6 +214,15 @@ class ConfigUtilsTest extends TestNGSuite with Matchers { mergeMaps(map2, map1, (a, b, k) => a.toString + b.toString) shouldBe Map("c" -> "21") mergeMaps(map2, map2, (a, b, k) => a.toString + b.toString) shouldBe Map("c" -> "22") } + + @Test def testNestedMergeConflict: Unit = { + val map1 = Map("c" -> Map("x" -> "1")) + val map2 = Map("c" -> Map("x" -> "1")) + mergeMaps(map1, map2) shouldBe Map("c" -> Map("x" -> "1")) + mergeMaps(map1, map2, (a, b, k) => a.toString + b.toString) shouldBe Map("c" -> Map("x" -> "12")) + mergeMaps(map2, map1, (a, b, k) => a.toString + b.toString) shouldBe Map("c" -> Map("x" -> "21")) + mergeMaps(map2, map2, (a, b, k) => a.toString + b.toString) shouldBe Map("c" -> Map("x" -> "22")) + } } object ConfigUtilsTest {