Skip to content

Commit 23b0153

Browse files
committed
Fixed integration test
1 parent f85af84 commit 23b0153

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

Diff for: internal/integrationtest/compile_3/compile_commands_test.go

+2-8
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,9 @@
1616
package compile_test
1717

1818
import (
19-
"encoding/json"
2019
"testing"
2120

2221
"github.com/arduino/arduino-cli/internal/integrationtest"
23-
"github.com/arduino/go-paths-helper"
2422
"github.com/stretchr/testify/require"
2523
"go.bug.st/testifyjson/requirejson"
2624
)
@@ -36,13 +34,9 @@ func TestCompileCommandsJSONGeneration(t *testing.T) {
3634
require.NoError(t, err)
3735

3836
// Create a test sketch
39-
out, _, err := cli.Run("sketch", "new", "Test", "--format", "json")
37+
_, _, err = cli.Run("sketch", "new", "Test")
4038
require.NoError(t, err)
41-
var s struct {
42-
Path string `json:"sketch_path"`
43-
}
44-
require.NoError(t, json.Unmarshal(out, &s))
45-
sketchPath := paths.New(s.Path)
39+
sketchPath := cli.WorkingDir().Join("Test")
4640
buildPath := sketchPath.Join("build")
4741

4842
{

0 commit comments

Comments
 (0)