Acceptance Test Updates (#218)
* compute: don't pass choices
* blockstorage: don't pass choices
* DumpResource Function
This function prints a resource in JSON format but retains the actual
field name rather than using the name specified in the JSON tag.
* New DumpResource
This version just converts the resource into JSON. The original is
being left in git history for posterity.
* Renaming DumpResource to PrintResource
* Removing all print functions in favor of PrintResource
* Rebase reconcilliation
diff --git a/acceptance/openstack/compute/v2/defsecrules_test.go b/acceptance/openstack/compute/v2/defsecrules_test.go
index ca221be..16c43f4 100644
--- a/acceptance/openstack/compute/v2/defsecrules_test.go
+++ b/acceptance/openstack/compute/v2/defsecrules_test.go
@@ -6,6 +6,7 @@
"testing"
"github.com/gophercloud/gophercloud/acceptance/clients"
+ "github.com/gophercloud/gophercloud/acceptance/tools"
dsr "github.com/gophercloud/gophercloud/openstack/compute/v2/extensions/defsecrules"
)
@@ -26,7 +27,7 @@
}
for _, defaultRule := range allDefaultRules {
- PrintDefaultRule(t, &defaultRule)
+ tools.PrintResource(t, defaultRule)
}
}
@@ -42,7 +43,7 @@
}
defer DeleteDefaultRule(t, client, defaultRule)
- PrintDefaultRule(t, &defaultRule)
+ tools.PrintResource(t, defaultRule)
}
func TestDefSecRulesGet(t *testing.T) {
@@ -62,5 +63,5 @@
t.Fatalf("Unable to get default rule %s: %v", defaultRule.ID, err)
}
- PrintDefaultRule(t, newDefaultRule)
+ tools.PrintResource(t, newDefaultRule)
}