blob: 54d01071856f9d028eea1337b092c525541bf0f1 [file] [log] [blame]
Jon Perrittb6823132015-01-21 15:03:58 -07001// +build acceptance
2
3package v1
4
5import (
6 "testing"
7
Jon Perritt27249f42016-02-18 10:35:59 -06008 "github.com/gophercloud/gophercloud"
9 "github.com/gophercloud/gophercloud/rackspace"
10 th "github.com/gophercloud/gophercloud/testhelper"
Jon Perrittb6823132015-01-21 15:03:58 -070011)
12
13func newClient(t *testing.T) *gophercloud.ServiceClient {
14 ao, err := rackspace.AuthOptionsFromEnv()
15 th.AssertNoErr(t, err)
16
17 client, err := rackspace.AuthenticatedClient(ao)
18 th.AssertNoErr(t, err)
19
20 c, err := rackspace.NewCDNV1(client, gophercloud.EndpointOpts{})
21 th.AssertNoErr(t, err)
22 return c
23}