Tests and bug fixes for UserID + Password.
diff --git a/openstack/identity/v3/tokens/requests.go b/openstack/identity/v3/tokens/requests.go
index 5be55ed..1790df5 100644
--- a/openstack/identity/v3/tokens/requests.go
+++ b/openstack/identity/v3/tokens/requests.go
@@ -30,7 +30,7 @@
ID *string `json:"id,omitempty"`
Name *string `json:"name,omitempty"`
Password string `json:"password"`
- Domain *domainReq `json:"domain"`
+ Domain *domainReq `json:"domain,omitempty"`
}
type passwordReq struct {
@@ -43,7 +43,7 @@
type identityReq struct {
Methods []string `json:"methods"`
- Password *passwordReq `json:"token,omitempty"`
+ Password *passwordReq `json:"password,omitempty"`
Token *tokenReq `json:"token,omitempty"`
}
@@ -54,7 +54,7 @@
type authReq struct {
Identity identityReq `json:"identity"`
- Scope *scopeReq `json:"scope"`
+ Scope *scopeReq `json:"scope,omitempty"`
}
type request struct {
@@ -162,7 +162,7 @@
// Configure the request for UserID and Password authentication.
req.Auth.Identity.Password = &passwordReq{
- User: userReq{ID: &ao.UserID},
+ User: userReq{ID: &ao.UserID, Password: ao.Password},
}
}
}