Update instance/associate with config group
diff --git a/rackspace/db/v1/instances/fixtures.go b/rackspace/db/v1/instances/fixtures.go
index cbd18da..bbf578b 100644
--- a/rackspace/db/v1/instances/fixtures.go
+++ b/rackspace/db/v1/instances/fixtures.go
@@ -164,3 +164,16 @@
`)
})
}
+
+func HandleAssociateGroupSuccessfully(t *testing.T, id string) {
+ th.Mux.HandleFunc("/instances/"+id, func(w http.ResponseWriter, r *http.Request) {
+ th.TestMethod(t, r, "PUT")
+ th.TestHeader(t, r, "X-Auth-Token", fake.TokenID)
+ th.TestJSONRequest(t, r, `{"instance": {"configuration": "{configGroupID}"}}`)
+
+ w.WriteHeader(http.StatusAccepted)
+ w.Header().Add("Content-Type", "application/json")
+
+ fmt.Fprintf(w, singleInstanceJson)
+ })
+}