fix tests (should be only running on the device)

This commit is contained in:
Siyuan Miao 2025-05-19 10:00:17 +02:00
parent 25a3b625fa
commit 5b8efd42d0
1 changed files with 3 additions and 1 deletions

View File

@ -1,3 +1,5 @@
//go:build arm && linux
package usbgadget
import (
@ -35,5 +37,5 @@ func TestUsbGadgetInit(t *testing.T) {
func TestUsbGadgetStrictModeInitFail(t *testing.T) {
usbConfig.strictMode = true
u := NewUsbGadget("test", usbDevices, usbConfig, nil)
assert.NotNil(t, u, "should be nil")
assert.Nil(t, u, "should be nil")
}