Skip to content

Commit

Permalink
cmd/govim: really ensure go-to-def tests have stable go.mod files (#750)
Browse files Browse the repository at this point in the history
In e5653c8 we sort to make go-to-def testscript tests go.mod stable. We
missed an instance as part of that change. Fix that.
  • Loading branch information
myitcv committed Feb 1, 2020
1 parent 4982748 commit 58660e5
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions cmd/govim/testdata/scenario_default/go_to_def_same_file.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@ vim ex 'set splitright'

# Definition in same file
vim ex 'e '$WORK/p.go
vim ex 'call cursor(6,15)'
vim ex 'call cursor(3,15)'
vim ex 'GOVIMGoToDef'
vim expr 'expand(''%:p'')'
stdout '^\Q"'$WORK'/p.go"\E$'
vim expr '[getcurpos()[1], getcurpos()[2]]'
stdout '^\Q[8,7]\E$'
stdout '^\Q[5,7]\E$'

# Assert that we have received no error (Type: 1) or warning (Type: 2) log messages
# Disabled pending resolution to https://github.com/golang/go/issues/34103
Expand All @@ -21,15 +21,9 @@ stdout '^\Q[8,7]\E$'
module mod.com/p

go 1.12

replace mod.com/q => ./q

-- p.go --
package p

import "mod.com/q"

const Name1 = q.Name
const Name2 = SameFile

const SameFile = "samefile"

0 comments on commit 58660e5

Please sign in to comment.