@@ -323,26 +323,22 @@ func TestUserLibs(t *testing.T) {
323323func TestSketchCommands (t * testing.T ) {
324324 defer makeTempDataDir (t )()
325325 defer makeTempSketchbookDir (t )()
326- //var d []byte
327- var exitCode int
328326 defer useSharedDownloadDir (t )()
329327
330- exitCode , _ = executeWithArgs (t , "sketch" , "new" , "Test" )
328+ exitCode , _ : = executeWithArgs (t , "sketch" , "new" , "Test" )
331329 require .Zero (t , exitCode , "exit code" )
332330}
333331
334332func TestLibDownloadAndInstall (t * testing.T ) {
335333 defer makeTempDataDir (t )()
336334 defer makeTempSketchbookDir (t )()
337- var d []byte
338- var exitCode int
339335 defer useSharedDownloadDir (t )()
340336
341- exitCode , _ = executeWithArgs (t , "core" , "update-index" )
337+ exitCode , _ : = executeWithArgs (t , "core" , "update-index" )
342338 require .Zero (t , exitCode , "exit code" )
343339
344340 // Download inexistent
345- exitCode , d = executeWithArgs (t , "lib" , "download" , "inexistentLibrary" , "--format" , "json" )
341+ exitCode , d : = executeWithArgs (t , "lib" , "download" , "inexistentLibrary" , "--format" , "json" )
346342 require .NotZero (t , exitCode , "exit code" )
347343 require .Contains (t , string (d ), "library inexistentLibrary not found" )
348344
@@ -576,11 +572,6 @@ func TestCoreCommands(t *testing.T) {
576572 defer makeTempSketchbookDir (t )()
577573 defer useSharedDownloadDir (t )()
578574
579- // Set staging dir to a temporary dir
580- tmp , err := ioutil .TempDir (os .TempDir (), "test" )
581- require .NoError (t , err , "making temporary staging dir" )
582- defer os .RemoveAll (tmp )
583-
584575 updateCoreIndex (t )
585576 AVR := "arduino:avr@" + detectLatestAVRCore (t )
586577
0 commit comments