Skip to content

Commit

Permalink
testament spec: remove errmsg alias of errormsg (#16188)
Browse files Browse the repository at this point in the history
  • Loading branch information
timotheecour authored Nov 30, 2020
1 parent 6114df3 commit 31a8cf1
Show file tree
Hide file tree
Showing 14 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion testament/specs.nim
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,7 @@ proc parseSpec*(filename: string): TSpec =
result.msg = e.value
if result.action != actionRun:
result.action = actionCompile
of "errormsg", "errmsg": # xxx just use errormsg, no need for such aliases
of "errormsg":
result.msg = e.value
result.action = actionReject
of "nimout":
Expand Down
2 changes: 1 addition & 1 deletion testament/tests/shouldfail/tfile.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
discard """
errmsg: "undeclared identifier: 'undefined'"
errormsg: "undeclared identifier: 'undefined'"
file: "notthisfile.nim"
"""

Expand Down
2 changes: 1 addition & 1 deletion tests/async/tdiscardableproc.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
discard """
errmsg: "Cannot make async proc discardable. Futures have to be checked with `asyncCheck` instead of discarded"
errormsg: "Cannot make async proc discardable. Futures have to be checked with `asyncCheck` instead of discarded"
"""

import async
Expand Down
2 changes: 1 addition & 1 deletion tests/destructor/tdestructor_too_late.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
discard """
errmsg: "cannot bind another '=destroy' to: Obj; previous declaration was constructed here implicitly: tdestructor_too_late.nim(7, 16)"
errormsg: "cannot bind another '=destroy' to: Obj; previous declaration was constructed here implicitly: tdestructor_too_late.nim(7, 16)"
"""
type Obj* = object
v*: int
Expand Down
2 changes: 1 addition & 1 deletion tests/errmsgs/t8610.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
discard """
errmsg: "invalid type: 'type int' for const"
errormsg: "invalid type: 'type int' for const"
"""
## issue #8610
const Foo = int
2 changes: 1 addition & 1 deletion tests/errmsgs/t9768.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
discard """
errmsg: "unhandled exception:"
errormsg: "unhandled exception:"
file: "system/fatal.nim"
nimout: '''
stack trace: (most recent call last)
Expand Down
2 changes: 1 addition & 1 deletion tests/errmsgs/tstaticexprscope.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
discard """
errmsg: "undeclared identifier: 'z'"
errormsg: "undeclared identifier: 'z'"
line: 11
"""

Expand Down
2 changes: 1 addition & 1 deletion tests/errmsgs/ttypeAllowed.nim
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
discard """
cmd: "nim check $file"
errmsg: ""
errormsg: ""
nimout: '''
ttypeAllowed.nim(13, 5) Error: invalid type: 'iterator (a: int, b: int, step: Positive): int{.inline, noSideEffect, gcsafe, locks: 0.}' for let
ttypeAllowed.nim(17, 7) Error: invalid type: 'iterator (a: int, b: int, step: Positive): int{.inline, noSideEffect, gcsafe, locks: 0.}' for const
Expand Down
2 changes: 1 addition & 1 deletion tests/lent/tnot_allowed_lent.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
discard """
errmsg: "expression has no address"
errormsg: "expression has no address"
"""
type
MyObject = object
Expand Down
2 changes: 1 addition & 1 deletion tests/lent/tnot_allowed_lent2.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
discard """
errmsg: "'x' cannot be assigned to"
errormsg: "'x' cannot be assigned to"
line: 10
"""

Expand Down
2 changes: 1 addition & 1 deletion tests/nimble/tnimblepathdollar_fault.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
discard """
errmsg: "cannot open file: pkgA/module"
errormsg: "cannot open file: pkgA/module"
"""

# see nims file; comment out `switch("noNimblePath")` there and there would be no error
Expand Down
2 changes: 1 addition & 1 deletion tests/proc/tfunc_type.nim
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

discard """
errmsg: "func keyword is not allowed in type descriptions, use proc with {.noSideEffect.} pragma instead"
errormsg: "func keyword is not allowed in type descriptions, use proc with {.noSideEffect.} pragma instead"
"""

type
Expand Down
2 changes: 1 addition & 1 deletion tests/proc/tillegalreturntype.nim
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
discard """
cmd: "nim check $file"
errmsg: ""
errormsg: ""
nimout: '''
tillegalreturntype.nim(11, 11) Error: return type 'typed' is only valid for macros and templates
tillegalreturntype.nim(14, 11) Error: return type 'untyped' is only valid for macros and templates
Expand Down
2 changes: 1 addition & 1 deletion tests/varres/tprevent_forloopvar_mutations.nim
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
discard """
errmsg: "type mismatch: got <int>"
errormsg: "type mismatch: got <int>"
line: 17
nimout: '''type mismatch: got <int>
but expected one of:
Expand Down

0 comments on commit 31a8cf1

Please sign in to comment.