diff --git a/utest/test/src-2/test/utest/AssertsTests.scala b/utest/test/src-2/test/utest/AssertsTests.scala index 8b33ec8..bc5362b 100644 --- a/utest/test/src-2/test/utest/AssertsTests.scala +++ b/utest/test/src-2/test/utest/AssertsTests.scala @@ -9,40 +9,46 @@ object AssertsTestsVersionSpecific extends utest.TestSuite{ test("failure"){ // Use compileError to check itself to verify that when it // doesn't throw an error, it actually does (super meta!) - * - compileError(""" - compileError("1 + 1").check( + test("1") { + compileError(""" + compileError("1 + 1").check( + "" + ) + """).check( + """ + compileError("1 + 1").check( + ^ + """, + "compileError check failed to have a compilation error" + ) + } + test("2") { + compileError(""" + val x = 0 + compileError("x + x").check( "" ) - """).check( - """ - compileError("1 + 1").check( - ^ - """, - "compileError check failed to have a compilation error" - ) - * - compileError(""" - val x = 0 - compileError("x + x").check( - "" + """).check( + """ + compileError("x + x").check( + ^ + """, + "compileError check failed to have a compilation error" ) + } + test("3") { + compileError(""" + compileError("1" * 2).check( + "" + ) """).check( - """ - compileError("x + x").check( - ^ - """, - "compileError check failed to have a compilation error" - ) - * - compileError(""" - compileError("1" * 2).check( - "" - ) - """).check( - """ - compileError("1" * 2).check( - ^ - """, - "You can only have literal strings in compileError" - ) + """ + compileError("1" * 2).check( + ^ + """, + "You can only have literal strings in compileError" + ) + } } test("compileTimeOnly"){