mirror of
https://github.com/golang/go
synced 2024-11-18 16:14:46 -07:00
internal/lsp: make pipe mode the default for command line tests
now there are no more race conditions in the jsonrpc or server code make connected pipe (rather than direct API) the default in the tests to make sure we stay clean. Change-Id: Id1ffede795a660dbf7b265b9e0419c60cf83c6e8 Reviewed-on: https://go-review.googlesource.com/c/tools/+/170181 Run-TryBot: Ian Cottrell <iancottrell@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Rebecca Stambler <rstambler@golang.org>
This commit is contained in:
parent
5d16bdd7b5
commit
e2f00d1e07
@ -40,10 +40,7 @@ func (l diagnostics) test(t *testing.T, e *packagestest.Exported) {
|
||||
if len(want) == 1 && want[0].Message == "" {
|
||||
continue
|
||||
}
|
||||
args := []string{}
|
||||
if *internalPipe {
|
||||
args = append(args, "-remote=internal")
|
||||
}
|
||||
args := []string{"-remote=internal"}
|
||||
args = append(args, "check", fname)
|
||||
app := &cmd.Application{}
|
||||
app.Config = *e.Config
|
||||
|
@ -5,7 +5,6 @@
|
||||
package cmd_test
|
||||
|
||||
import (
|
||||
"flag"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"strings"
|
||||
@ -24,8 +23,6 @@ const (
|
||||
expectedFormatCount = 4
|
||||
)
|
||||
|
||||
var internalPipe = flag.Bool("pipe", false, "connect the command line client to a server through a pipe")
|
||||
|
||||
func TestCommandLine(t *testing.T) {
|
||||
packagestest.TestAll(t, testCommandLine)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user