From 49e82a41879393691e466dc397b79e2862330206 Mon Sep 17 00:00:00 2001 From: Petr Pucil Date: Sat, 9 Mar 2024 14:57:53 +0100 Subject: [PATCH] TranslatorSpec: use the `ResultMap` alias in conversion from lang-result pairs See https://stackoverflow.com/a/36591463 --- .../scala/io/kaitai/struct/translators/TranslatorSpec.scala | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/jvm/src/test/scala/io/kaitai/struct/translators/TranslatorSpec.scala b/jvm/src/test/scala/io/kaitai/struct/translators/TranslatorSpec.scala index 6c6267c5e..9eaee3f4b 100644 --- a/jvm/src/test/scala/io/kaitai/struct/translators/TranslatorSpec.scala +++ b/jvm/src/test/scala/io/kaitai/struct/translators/TranslatorSpec.scala @@ -819,10 +819,10 @@ class TranslatorSpec extends AnyFunSpec { runTest(src, tp, expType, expOut) def everybody(src: String, expOut: String, expType: DataType = CalcIntType)(implicit pos: Position) = - runTest(src, Always(CalcIntType), expType, ALL_LANGS.map((langObj) => langObj -> expOut).to(ListMap)) + runTest(src, Always(CalcIntType), expType, ResultMap(ALL_LANGS.map((langObj) => langObj -> expOut).toSeq:_*)) def everybodyExcept(src: String, commonExpOut: String, rm: ResultMap, expType: DataType = CalcIntType)(implicit pos: Position) = - runTest(src, Always(CalcIntType), expType, ALL_LANGS.map((langObj) => + runTest(src, Always(CalcIntType), expType, ResultMap(ALL_LANGS.map((langObj) => langObj -> rm.getOrElse(langObj, commonExpOut) - ).to(ListMap)) + ).toSeq:_*)) }