scalametaParserTest :: FilePath -> TestTree
scalametaParserTest f =
  goldenVsStringDiff (dropExtension (takeBaseName f)) (\ref new -> ["diff", "-u", ref, new]) f $ do
    parsed <- eitherDecodeFileStrict f :: IO (Either String Source)
    either error ((encodeUtf8 . pack <$>) . runNodeScalametaParsers . show . pretty) parsed
scalametaParserTest :: FilePath -> TestTree
scalametaParserTest f =
  goldenVsStringDiff (dropExtension (takeBaseName f)) (\ref new -> ["diff", "-u", ref, new]) f $ do
    parsed <- eitherDecodeFileStrict f :: IO (Either String Source)
    either error ((encodeUtf8 . pack <$>) . runNodeScalametaParsers . show . pretty) parsed
scalametaParserTest f =
  goldenVsStringDiff (dropExtension (takeBaseName f)) (\ref new -> ["diff", "-u", ref, new]) f $ do
    parsed <- eitherDecodeFileStrict f :: IO (Either String Source)
    either error ((encodeUtf8 . pack <$>) . runNodeScalametaParsers . show . pretty) parsed