Ash Wilson | b482d54 | 2014-08-28 15:48:04 -0400 | [diff] [blame] | 1 | package tokens |
2 | |||||
3 | import ( | ||||
4 | "testing" | ||||
5 | |||||
6 | "github.com/rackspace/gophercloud" | ||||
7 | ) | ||||
8 | |||||
9 | func TestTokenURL(t *testing.T) { | ||||
10 | setup() | ||||
11 | defer teardown() | ||||
12 | |||||
13 | client := gophercloud.ServiceClient{Endpoint: endpoint()} | ||||
14 | |||||
15 | expected := endpoint() + "auth/tokens" | ||||
16 | actual := getTokenURL(&client) | ||||
17 | if actual != expected { | ||||
18 | t.Errorf("Expected URL %s, but was %s", expected, actual) | ||||
19 | } | ||||
20 | } |