mirror of
https://github.com/hybridgroup/gobot.git
synced 2025-05-14 19:29:32 +08:00
21 lines
354 B
Go
21 lines
354 B
Go
package bebop
|
|
|
|
import (
|
|
"strings"
|
|
"testing"
|
|
|
|
"github.com/stretchr/testify/assert"
|
|
|
|
"gobot.io/x/gobot/v2"
|
|
)
|
|
|
|
var _ gobot.Driver = (*Driver)(nil)
|
|
|
|
func TestBebopDriverName(t *testing.T) {
|
|
a := initTestBebopAdaptor()
|
|
d := NewDriver(a)
|
|
assert.True(t, strings.HasPrefix(d.Name(), "Bebop"))
|
|
d.SetName("NewName")
|
|
assert.Equal(t, "NewName", d.Name())
|
|
}
|