File tree Expand file tree Collapse file tree 2 files changed +9
-6
lines changed
internal/orchestrator/bricks Expand file tree Collapse file tree 2 files changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -57,13 +57,18 @@ func TestBrickCreate(t *testing.T) {
5757 })
5858
5959 t .Run ("do not fail if a mandatory variable is not present" , func (t * testing.T ) {
60+ tempDummyApp := paths .New ("testdata/dummy-app.temp" )
61+ err := tempDummyApp .RemoveAll ()
62+ require .Nil (t , err )
63+ require .Nil (t , paths .New ("testdata/dummy-app" ).CopyDirTo (tempDummyApp ))
64+
6065 req := BrickCreateUpdateRequest {ID : "arduino:arduino_cloud" , Variables : map [string ]string {
6166 "ARDUINO_SECRET" : "a-secret-a" ,
6267 }}
63- err = brickService .BrickCreate (req , f .Must (app .Load ("testdata/dummy-app" )))
68+ err = brickService .BrickCreate (req , f .Must (app .Load (tempDummyApp . String () )))
6469 require .NoError (t , err )
6570
66- after , err := app .Load ("testdata/dummy-app" )
71+ after , err := app .Load (tempDummyApp . String () )
6772 require .Nil (t , err )
6873 require .Len (t , after .Descriptor .Bricks , 1 )
6974 require .Equal (t , "arduino:arduino_cloud" , after .Descriptor .Bricks [0 ].ID )
Original file line number Diff line number Diff line change 11name : Copy of Blinking LED from Arduino Cloud
22description : Control the LED from the Arduino IoT Cloud using RPC calls
3+ icon : ☁️
34ports : []
45bricks :
5- - arduino:arduino_cloud :
6- variables :
7- ARDUINO_SECRET : a-secret-a
8- icon : ☁️
6+ - arduino:arduino_cloud:
You can’t perform that action at this time.
0 commit comments