Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 87561fe

Browse files
cmaglieper1234
andcommitted
Apply suggestions from code review
Co-authored-by: per1234 <accounts@perglass.com>
1 parent 82e47d3 commit 87561fe

File tree

4 files changed

+3
-19
lines changed

4 files changed

+3
-19
lines changed

‎Taskfile.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ tasks:
9090
9191
# Source: https://github.com/arduino/tooling-project-assets/blob/main/workflow-templates/assets/test-go-task/Taskfile.yml
9292
go:test:
93-
desc: Run unit tests and part of the integration tests
93+
desc: Run unit tests and the Go-based integration tests
9494
deps:
9595
- task: go:build
9696
dir: '{{default "./" .GO_MODULE_PATH}}'

‎internal/integrationtest/arduino-cli.go‎

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ func NewArduinoCliWithinEnvironment(env *testsuite.Environment, config *ArduinoC
6161
cli := &ArduinoCLI{
6262
path: config.ArduinoCLIPath,
6363
t: require.New(env.T()),
64-
dataDir: env.RootDir().Join("arduino15"),
64+
dataDir: env.RootDir().Join("Arduino15"),
6565
sketchbookDir: env.RootDir().Join("Arduino"),
6666
stagingDir: env.RootDir().Join("arduino15/staging"),
6767
}
@@ -153,14 +153,6 @@ func (cli *ArduinoCLI) StartDaemon(verbose bool) string {
153153

154154
cli.t.NoError(cliProc.Start())
155155
cli.proc = cliProc
156-
157-
// var daemonAddr struct {
158-
// IP string
159-
// Port string
160-
// }
161-
// dec := json.NewDecoder(stdout)
162-
// cli.t.NoError(dec.Decode(&daemonAddr))
163-
// cli.daemonAddr = daemonAddr.IP + ":" + daemonAddr.Port
164156
cli.daemonAddr = "127.0.0.1:50051"
165157

166158
copy := func(dst io.Writer, src io.Reader) {

‎internal/integrationtest/core/core_test.go‎

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,6 @@ func TestCoreSearch(t *testing.T) {
6262
out, _, err = cli.Run("core", "search", "test_core", "--all", "--format", "json", "--additional-urls="+url.String())
6363
require.NoError(t, err)
6464
requirejson.Len(t, out, 2)
65-
// requirejson.Len(t, out, 3) // Test failure
6665

6766
checkPlatformIsInJSONOutput := func(stdout []byte, id, version string) {
6867
jqquery := fmt.Sprintf(`[{id:"%s", latest:"%s"}]`, id, version)
@@ -74,7 +73,6 @@ func TestCoreSearch(t *testing.T) {
7473
require.NoError(t, err)
7574
checkPlatformIsInJSONOutput(out, "Retrokits-RK002:arm", "1.0.5")
7675
checkPlatformIsInJSONOutput(out, "Retrokits-RK002:arm", "1.0.6")
77-
//checkPlatformIsInJSONOutput(out, "Retrokits-RK002:arm", "1.0.9") // Test failure
7876

7977
// Search using Retrokit Package Maintainer
8078
out, _, err = cli.Run("core", "search", "Retrokits-RK002", "--all", "--additional-urls="+url.String(), "--format", "json")
@@ -93,7 +91,6 @@ func TestCoreSearch(t *testing.T) {
9391
require.NoError(t, err)
9492
checkPlatformIsInJSONOutput(out, "Package:x86", "1.2.3")
9593

96-
// Check search with case, accents and spaces
9794
runSearch := func(searchArgs string, expectedIDs ...string) {
9895
args := []string{"core", "search", "--format", "json"}
9996
args = append(args, strings.Split(searchArgs, " ")...)
@@ -106,6 +103,7 @@ func TestCoreSearch(t *testing.T) {
106103
}
107104
}
108105

106+
// Check search with case, accents and spaces
109107
runSearch("mkr1000", "arduino:samd")
110108
runSearch("mkr 1000", "arduino:samd")
111109

‎internal/integrationtest/daemon/daemon_compile_test.go‎

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -74,9 +74,6 @@ func TestDaemonCompileOptions(t *testing.T) {
7474
fmt.Println("COMPILE ERROR>", err)
7575
break
7676
}
77-
// if msg.OutStream != nil {
78-
// fmt.Printf("COMPILE> %v\n", string(msg.GetOutStream()))
79-
// }
8077
if msg.ErrStream != nil {
8178
fmt.Printf("COMPILE> %v\n", string(msg.GetErrStream()))
8279
}
@@ -91,9 +88,6 @@ func TestDaemonCompileOptions(t *testing.T) {
9188
break
9289
}
9390
require.NoError(t, err)
94-
// if msg.OutStream != nil {
95-
// fmt.Printf("COMPILE> %v\n", string(msg.GetOutStream()))
96-
// }
9791
if msg.ErrStream != nil {
9892
fmt.Printf("COMPILE> %v\n", string(msg.GetErrStream()))
9993
}

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /