2016-12-19 23:21:47 +08:00
|
|
|
package bb8
|
|
|
|
|
2016-12-23 16:36:16 +08:00
|
|
|
import (
|
|
|
|
"testing"
|
|
|
|
|
|
|
|
"gobot.io/x/gobot"
|
|
|
|
"gobot.io/x/gobot/gobottest"
|
|
|
|
|
|
|
|
"gobot.io/x/gobot/platforms/ble"
|
|
|
|
)
|
2016-12-19 23:21:47 +08:00
|
|
|
|
2016-12-23 16:23:18 +08:00
|
|
|
var _ gobot.Driver = (*BB8Driver)(nil)
|
2016-12-23 16:36:16 +08:00
|
|
|
|
|
|
|
func initTestBB8Driver() *BB8Driver {
|
|
|
|
d := NewDriver(ble.NewClientAdaptor("D7:99:5A:26:EC:38"))
|
|
|
|
return d
|
|
|
|
}
|
|
|
|
|
|
|
|
func TestBB8Driver(t *testing.T) {
|
|
|
|
d := initTestBB8Driver()
|
|
|
|
gobottest.Assert(t, d.Name(), "BB-8")
|
|
|
|
}
|