lundi 14 octobre 2019

Kotlintest - Unresolved reference shouldMatchJson

Seems like I can't access shouldMatchJson matcher from Kotlintest v3.4.2 the way is documented in https://github.com/kotlintest/kotlintest/blob/master/doc/matchers.md. I get unresolved reference and I seem unable to import it. The code says it's an extension method to String class but tried with strings and even """{}""" but can't access that method. Am I doing something wrong? All other matchers are ok.

class Test : StringSpec ({
    "Test a json" {
        "{}".shouldMatchJson("{}")
    }
})

unresolved reference

Aucun commentaire:

Enregistrer un commentaire