We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5c12c8f commit 98ee870Copy full SHA for 98ee870
arduino/libraries/librariesmanager/librariesmanager_test.go
@@ -0,0 +1,18 @@
1
+package librariesmanager
2
+
3
+import (
4
+ "testing"
5
6
+ "github.com/arduino/arduino-cli/arduino/libraries"
7
+ "github.com/arduino/go-paths-helper"
8
+ "github.com/stretchr/testify/require"
9
+)
10
11
+func Test_RescanLibrariesCallClear(t *testing.T) {
12
+ baseDir := paths.New(t.TempDir())
13
+ lm := NewLibraryManager(baseDir.Join("index_dir"), baseDir.Join("downloads_dir"))
14
+ lm.Libraries["testLibA"] = libraries.List{}
15
+ lm.Libraries["testLibB"] = libraries.List{}
16
+ lm.RescanLibraries()
17
+ require.Len(t, lm.Libraries, 0)
18
+}
0 commit comments