fix AccessToken struct -> User json Unmarshal
Change-Id: I4e07da36a46285c68c94ee2857a9e8f85b161e92
This commit is contained in:
parent
c8dab92a7c
commit
784256a823
@ -42,7 +42,8 @@ func TestVerifyLocalPKIZ(t *testing.T) {
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
fmt.Println(access)
|
||||
user := access.Access.User.(map[string]interface{})
|
||||
fmt.Println(user["roles"])
|
||||
project := access.Access.Token.Project
|
||||
if project.Name != "demo" {
|
||||
t.Fail()
|
||||
|
@ -24,7 +24,7 @@ import (
|
||||
|
||||
type AccessType struct {
|
||||
Token Token `json:"token"`
|
||||
User interface{} `json:"id"`
|
||||
User interface{} `json:"user"`
|
||||
ServiceCatalog []ServiceCatalogEntry `json:"servicecatalog"`
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user