Skip to content

Commit

Permalink
Use 1-based column numbers in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
forki committed Jul 8, 2019
1 parent 4a1315e commit bc334c5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion tests/fsharp/Compiler/CompilerAssert.fs
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ module CompilerAssert =
|> Array.iter (fun info ->
Assert.AreEqual(FSharpErrorSeverity.Error, info.Severity)
Assert.AreEqual(expectedErrorNumber, info.ErrorNumber, "expectedErrorNumber")
Assert.AreEqual(expectedErrorRange, (info.StartLineAlternate, info.StartColumn, info.EndLineAlternate, info.EndColumn), "expectedErrorRange")
Assert.AreEqual(expectedErrorRange, (info.StartLineAlternate, info.StartColumn + 1, info.EndLineAlternate, info.EndColumn + 1), "expectedErrorRange")
Assert.AreEqual(expectedErrorMsg, info.Message, "expectedErrorMsg")
)

Expand Down
4 changes: 2 additions & 2 deletions tests/fsharp/Compiler/Language/AnonRecordTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ type RefClass<'a when 'a : not struct>() = class end
let rAnon = RefClass<struct {| R: int |}>()
"""
1
(3, 12, 3, 41)
(3, 13, 3, 42)
"A generic construct requires that the type 'struct {|R : int|}' have reference semantics, but it does not, i.e. it is a struct"

[<Test>]
Expand All @@ -42,5 +42,5 @@ type StructClass<'a when 'a : struct>() = class end
let sAnon = StructClass<{| S: int |}>()
"""
1
(3, 12, 3, 37)
(3, 13, 3, 38)
"A generic construct requires that the type '{|S : int|}' is a CLI or F# struct type"

0 comments on commit bc334c5

Please sign in to comment.