File tree Expand file tree Collapse file tree 3 files changed +9
-3
lines changed
testdata/SketchWithProfiles Expand file tree Collapse file tree 3 files changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -187,6 +187,9 @@ type ProfileRequiredLibraries []*ProfileLibraryReference
187
187
188
188
// AsYaml outputs the required libraries as Yaml
189
189
func (p * ProfileRequiredLibraries ) AsYaml () string {
190
+ if len (* p ) == 0 {
191
+ return ""
192
+ }
190
193
res := " libraries:\n "
191
194
for _ , lib := range * p {
192
195
res += lib .AsYaml ()
Original file line number Diff line number Diff line change 16
16
package sketch
17
17
18
18
import (
19
- "fmt"
20
19
"testing"
21
20
22
21
"github.com/arduino/go-paths-helper"
@@ -28,7 +27,6 @@ func TestProjectFileLoading(t *testing.T) {
28
27
sketchProj := paths .New ("testdata" , "SketchWithProfiles" , "sketch.yml" )
29
28
proj , err := LoadProjectFile (sketchProj )
30
29
require .NoError (t , err )
31
- fmt .Println (proj )
32
30
golden , err := sketchProj .ReadFile ()
33
31
require .NoError (t , err )
34
32
require .Equal (t , proj .AsYaml (), string (golden ))
@@ -37,7 +35,6 @@ func TestProjectFileLoading(t *testing.T) {
37
35
sketchProj := paths .New ("testdata" , "SketchWithDefaultFQBNAndPort" , "sketch.yml" )
38
36
proj , err := LoadProjectFile (sketchProj )
39
37
require .NoError (t , err )
40
- fmt .Println (proj )
41
38
golden , err := sketchProj .ReadFile ()
42
39
require .NoError (t , err )
43
40
require .Equal (t , proj .AsYaml (), string (golden ))
Original file line number Diff line number Diff line change @@ -9,6 +9,12 @@ profiles:
9
9
- Arduino_ConnectionHandler (0.6.4)
10
10
- TinyDHT sensor library (1.1.0)
11
11
12
+ nanorp_nolib :
13
+ fqbn : arduino:mbed_nano:nanorp2040connect
14
+ programmer : p1
15
+ platforms :
16
+ - platform : arduino:mbed_nano (2.1.0)
17
+
12
18
another_profile_name :
13
19
notes : testing the limit of the AVR platform, may be unstable
14
20
fqbn : arduino:avr:uno
You can’t perform that action at this time.
0 commit comments