Fix showing the test name

This commit is contained in:
Filip Gralinski 2021-05-29 19:12:24 +02:00
parent 30c7727d6a
commit f95fc680ba

View File

@ -9,6 +9,8 @@ import Handler.SubmissionView
import Handler.TagUtils
import Handler.JWT
import Prelude (read)
import Data.Diff
import qualified Yesod.Table as Table
@ -41,7 +43,7 @@ data TestReference = TestReference Text Text
instance ToJSON TestReference where
toJSON (TestReference metric n) = object
[ "name" .= n,
"metric" .= metric
"metric" .= (Data.Text.pack $ evaluationSchemeName $ read $ Data.Text.unpack metric)
]
instance ToSchema TestReference where