Merge pull request #265 from smashwilson/unbreak-acceptance
[wip] Unbreak acceptance
diff --git a/acceptance/openstack/blockstorage/v1/volumes_test.go b/acceptance/openstack/blockstorage/v1/volumes_test.go
index f84f5cb..6739a99 100644
--- a/acceptance/openstack/blockstorage/v1/volumes_test.go
+++ b/acceptance/openstack/blockstorage/v1/volumes_test.go
@@ -3,7 +3,6 @@
package v1
import (
- "fmt"
"os"
"testing"
@@ -68,7 +67,7 @@
t.Error(err)
return
}
- fmt.Printf("Got volume: %+v\n", v)
+ t.Logf("Got volume: %+v\n", v)
if v.Name != "gophercloud-updated-volume" {
t.Errorf("Unable to update volume: Expected name: gophercloud-updated-volume\nActual name: %s", v.Name)
diff --git a/acceptance/openstack/compute/v2/flavors_test.go b/acceptance/openstack/compute/v2/flavors_test.go
index cf547f2..9f51b12 100644
--- a/acceptance/openstack/compute/v2/flavors_test.go
+++ b/acceptance/openstack/compute/v2/flavors_test.go
@@ -17,7 +17,7 @@
t.Logf("ID\tRegion\tName\tStatus\tCreated")
- pager := flavors.List(client, nil)
+ pager := flavors.ListDetail(client, nil)
count, pages := 0, 0
pager.EachPage(func(page pagination.Page) (bool, error) {
t.Logf("---")
diff --git a/acceptance/openstack/compute/v2/servers_test.go b/acceptance/openstack/compute/v2/servers_test.go
index 00299c0..e223c18 100644
--- a/acceptance/openstack/compute/v2/servers_test.go
+++ b/acceptance/openstack/compute/v2/servers_test.go
@@ -3,7 +3,6 @@
package v2
import (
- "fmt"
"os"
"testing"
@@ -42,7 +41,7 @@
return true, nil
})
- fmt.Printf("--------\n%d servers listed on %d pages.\n", count, pages)
+ t.Logf("--------\n%d servers listed on %d pages.\n", count, pages)
}
func networkingClient() (*gophercloud.ServiceClient, error) {
diff --git a/acceptance/rackspace/compute/v2/flavors_test.go b/acceptance/rackspace/compute/v2/flavors_test.go
index 248ab91..4618ecc 100644
--- a/acceptance/rackspace/compute/v2/flavors_test.go
+++ b/acceptance/rackspace/compute/v2/flavors_test.go
@@ -15,7 +15,7 @@
th.AssertNoErr(t, err)
count := 0
- err = flavors.List(client, nil).EachPage(func(page pagination.Page) (bool, error) {
+ err = flavors.ListDetail(client, nil).EachPage(func(page pagination.Page) (bool, error) {
count++
t.Logf("-- Page %0d --", count)
diff --git a/openstack/compute/v2/flavors/requests.go b/openstack/compute/v2/flavors/requests.go
index 95eb7f9..065a2ec 100644
--- a/openstack/compute/v2/flavors/requests.go
+++ b/openstack/compute/v2/flavors/requests.go
@@ -41,10 +41,10 @@
return q.String(), nil
}
-// List instructs OpenStack to provide a list of flavors.
+// ListDetail instructs OpenStack to provide a list of flavors.
// You may provide criteria by which List curtails its results for easier processing.
// See ListOpts for more details.
-func List(client *gophercloud.ServiceClient, opts ListOptsBuilder) pagination.Pager {
+func ListDetail(client *gophercloud.ServiceClient, opts ListOptsBuilder) pagination.Pager {
url := listURL(client)
if opts != nil {
query, err := opts.ToFlavorListQuery()
diff --git a/openstack/compute/v2/flavors/requests_test.go b/openstack/compute/v2/flavors/requests_test.go
index bc9b82e..fbd7c33 100644
--- a/openstack/compute/v2/flavors/requests_test.go
+++ b/openstack/compute/v2/flavors/requests_test.go
@@ -60,7 +60,7 @@
})
pages := 0
- err := List(fake.ServiceClient(), &ListOpts{}).EachPage(func(page pagination.Page) (bool, error) {
+ err := ListDetail(fake.ServiceClient(), nil).EachPage(func(page pagination.Page) (bool, error) {
pages++
actual, err := ExtractFlavors(page)
diff --git a/openstack/objectstorage/v1/objects/requests.go b/openstack/objectstorage/v1/objects/requests.go
index 1b6cb5c..0ad0315 100644
--- a/openstack/objectstorage/v1/objects/requests.go
+++ b/openstack/objectstorage/v1/objects/requests.go
@@ -49,7 +49,6 @@
if opts != nil {
full, query, err := opts.ToObjectListParams()
if err != nil {
- fmt.Printf("Error building query string: %v", err)
return pagination.Pager{Err: err}
}
url += query
diff --git a/pagination/linked.go b/pagination/linked.go
index 447d4b1..461fa49 100644
--- a/pagination/linked.go
+++ b/pagination/linked.go
@@ -39,8 +39,6 @@
return "", nil
}
- fmt.Printf("key = %#v, path = %#v, value = %#v\n", key, path, value)
-
if len(path) > 0 {
submap, ok = value.(map[string]interface{})
if !ok {
diff --git a/rackspace/compute/v2/flavors/delegate.go b/rackspace/compute/v2/flavors/delegate.go
index 2cf31b5..6bfc20c 100644
--- a/rackspace/compute/v2/flavors/delegate.go
+++ b/rackspace/compute/v2/flavors/delegate.go
@@ -30,9 +30,9 @@
return q.String(), nil
}
-// List enumerates the server images available to your account.
-func List(client *gophercloud.ServiceClient, opts os.ListOptsBuilder) pagination.Pager {
- return os.List(client, opts)
+// ListDetail enumerates the server images available to your account.
+func ListDetail(client *gophercloud.ServiceClient, opts os.ListOptsBuilder) pagination.Pager {
+ return os.ListDetail(client, opts)
}
// Get returns details about a single flavor, identity by ID.
diff --git a/rackspace/compute/v2/flavors/delegate_test.go b/rackspace/compute/v2/flavors/delegate_test.go
index b2a2ea2..204081d 100644
--- a/rackspace/compute/v2/flavors/delegate_test.go
+++ b/rackspace/compute/v2/flavors/delegate_test.go
@@ -32,7 +32,7 @@
})
count := 0
- err := List(client.ServiceClient(), nil).EachPage(func(page pagination.Page) (bool, error) {
+ err := ListDetail(client.ServiceClient(), nil).EachPage(func(page pagination.Page) (bool, error) {
actual, err := ExtractFlavors(page)
th.AssertNoErr(t, err)
th.CheckDeepEquals(t, ExpectedFlavorSlice, actual)