Skip to content

Commit f21e86c

Browse files
committed
Renamed inst -> grpcInst
1 parent 0896f4c commit f21e86c

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

internal/integrationtest/daemon/daemon_board_watch_test.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,24 +34,24 @@ func TestArduinoCliDaemon(t *testing.T) {
3434
env, cli := createEnvForDaemon(t)
3535
defer env.CleanUp()
3636

37-
inst := cli.Create()
38-
require.NoError(t, inst.Init("", "", func(ir *commands.InitResponse) {
37+
grpcInst := cli.Create()
38+
require.NoError(t, grpcInst.Init("", "", func(ir *commands.InitResponse) {
3939
fmt.Printf("INIT> %v\n", ir.GetMessage())
4040
}))
4141

4242
// Run a one-shot board list
43-
boardListResp, err := inst.BoardList(time.Second)
43+
boardListResp, err := grpcInst.BoardList(time.Second)
4444
require.NoError(t, err)
4545
fmt.Printf("Got boardlist response with %d ports\n", len(boardListResp.GetPorts()))
4646

4747
// Run a one-shot board list again (should not fail)
48-
boardListResp, err = inst.BoardList(time.Second)
48+
boardListResp, err = grpcInst.BoardList(time.Second)
4949
require.NoError(t, err)
5050
fmt.Printf("Got boardlist response with %d ports\n", len(boardListResp.GetPorts()))
5151

5252
testWatcher := func() {
5353
// Run watcher
54-
watcher, err := inst.BoardListWatch()
54+
watcher, err := grpcInst.BoardListWatch()
5555
require.NoError(t, err)
5656
ctx, cancel := context.WithCancel(context.Background())
5757
go func() {

internal/integrationtest/daemon/daemon_compile_test.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,12 @@ func TestDaemonCompileOptions(t *testing.T) {
3333
env, cli := createEnvForDaemon(t)
3434
defer env.CleanUp()
3535

36-
inst := cli.Create()
37-
require.NoError(t, inst.Init("", "", func(ir *commands.InitResponse) {
36+
grpcInst := cli.Create()
37+
require.NoError(t, grpcInst.Init("", "", func(ir *commands.InitResponse) {
3838
fmt.Printf("INIT> %v\n", ir.GetMessage())
3939
}))
4040

41-
plInst, err := inst.PlatformInstall(context.Background(), "arduino", "avr", "1.8.5", true)
41+
plInst, err := grpcInst.PlatformInstall(context.Background(), "arduino", "avr", "1.8.5", true)
4242
require.NoError(t, err)
4343
for {
4444
msg, err := plInst.Recv()
@@ -56,13 +56,13 @@ func TestDaemonCompileOptions(t *testing.T) {
5656
require.NoError(t, err)
5757

5858
// Re-init instance to update changes
59-
require.NoError(t, inst.Init("", "", func(ir *commands.InitResponse) {
59+
require.NoError(t, grpcInst.Init("", "", func(ir *commands.InitResponse) {
6060
fmt.Printf("INIT> %v\n", ir.GetMessage())
6161
}))
6262

6363
// Build sketch (with errors)
6464
sk := paths.New("testdata", "bare_minimum")
65-
compile, err := inst.Compile(context.Background(), "arduino:avr:uno:some_menu=bad", sk.String())
65+
compile, err := grpcInst.Compile(context.Background(), "arduino:avr:uno:some_menu=bad", sk.String())
6666
require.NoError(t, err)
6767
for {
6868
msg, err := compile.Recv()
@@ -83,7 +83,7 @@ func TestDaemonCompileOptions(t *testing.T) {
8383
}
8484

8585
// Build sketch (without errors)
86-
compile, err = inst.Compile(context.Background(), "arduino:avr:uno:some_menu=good", sk.String())
86+
compile, err = grpcInst.Compile(context.Background(), "arduino:avr:uno:some_menu=good", sk.String())
8787
require.NoError(t, err)
8888
for {
8989
msg, err := compile.Recv()

0 commit comments

Comments
 (0)