diff options
author | Collin Guarino <collin.guarino@gmail.com> | 2016-02-18 23:30:40 -0500 |
---|---|---|
committer | Collin Guarino <collin.guarino@gmail.com> | 2016-02-18 23:30:40 -0500 |
commit | a95deb0690428f3c793ae7b4e2401ff56de72343 (patch) | |
tree | f16db5adb2f62fa034f962445ccb3179905d2bb7 /light_test.go | |
parent | 4715205f959490a55b8a2ad8aef56ce503709dbb (diff) |
Implemented Bridge.Login() func that will assign Bridge.Username and create the user if it does not exist. Also convered more functions to Bridge.func()
Diffstat (limited to 'light_test.go')
-rw-r--r-- | light_test.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/light_test.go b/light_test.go index bdf589f..22b977e 100644 --- a/light_test.go +++ b/light_test.go @@ -15,8 +15,9 @@ import ( func TestSetLightState(t *testing.T) { fmt.Println("\nTESTING LIGHT STATE:\n\n") - bridge, _ := NewBridge("192.168.1.128", "427de8bd6d49f149c8398e4fc08f") - nameTest, _ := GetLightByName(bridge, "Desk Light") // Also tests GetAllLights + bridge, _ := NewBridge("192.168.1.128") + bridge.Login("427de8bd6d49f149c8398e4fc08f") + nameTest, _ := bridge.GetLightByName("Desk Light") // Also tests GetAllLights _ = nameTest selectedLight, _ := GetLightByIndex(bridge, 7) |