Skip to content
This repository was archived by the owner on Aug 1, 2023. It is now read-only.

Commit d87c7d6

Browse files
author
Jamie Hannaford
committed
test fixes
1 parent b9aa87f commit d87c7d6

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

openstack/db/v1/configurations/requests_test.go

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,15 @@ var (
2727
func TestList(t *testing.T) {
2828
th.SetupHTTP()
2929
defer th.TeardownHTTP()
30-
fixture.SetupHandler(t, _baseURL, "GET", "", listConfigsJSON, 200)
30+
fixture.SetupHandler(t, _baseURL, "GET", "", ListConfigsJSON, 200)
3131

3232
count := 0
3333
err := List(fake.ServiceClient()).EachPage(func(page pagination.Page) (bool, error) {
3434
count++
3535
actual, err := ExtractConfigs(page)
3636
th.AssertNoErr(t, err)
3737

38-
expected := []Config{exampleConfig}
38+
expected := []Config{ExampleConfig}
3939
th.AssertDeepEquals(t, expected, actual)
4040

4141
return true, nil
@@ -48,17 +48,17 @@ func TestList(t *testing.T) {
4848
func TestGet(t *testing.T) {
4949
th.SetupHTTP()
5050
defer th.TeardownHTTP()
51-
fixture.SetupHandler(t, resURL, "GET", "", getConfigJSON, 200)
51+
fixture.SetupHandler(t, resURL, "GET", "", GetConfigJSON, 200)
5252

5353
config, err := Get(fake.ServiceClient(), configID).Extract()
5454
th.AssertNoErr(t, err)
55-
th.AssertDeepEquals(t, &exampleConfig, config)
55+
th.AssertDeepEquals(t, &ExampleConfig, config)
5656
}
5757

5858
func TestCreate(t *testing.T) {
5959
th.SetupHTTP()
6060
defer th.TeardownHTTP()
61-
fixture.SetupHandler(t, _baseURL, "POST", createReq, createConfigJSON, 200)
61+
fixture.SetupHandler(t, _baseURL, "POST", CreateReq, CreateConfigJSON, 200)
6262

6363
opts := CreateOpts{
6464
Datastore: &DatastoreOpts{
@@ -75,13 +75,13 @@ func TestCreate(t *testing.T) {
7575

7676
config, err := Create(fake.ServiceClient(), opts).Extract()
7777
th.AssertNoErr(t, err)
78-
th.AssertDeepEquals(t, &exampleConfigWithValues, config)
78+
th.AssertDeepEquals(t, &ExampleConfigWithValues, config)
7979
}
8080

8181
func TestUpdate(t *testing.T) {
8282
th.SetupHTTP()
8383
defer th.TeardownHTTP()
84-
fixture.SetupHandler(t, resURL, "PATCH", updateReq, "", 200)
84+
fixture.SetupHandler(t, resURL, "PATCH", UpdateReq, "", 200)
8585

8686
opts := UpdateOpts{
8787
Values: map[string]interface{}{
@@ -96,7 +96,7 @@ func TestUpdate(t *testing.T) {
9696
func TestReplace(t *testing.T) {
9797
th.SetupHTTP()
9898
defer th.TeardownHTTP()
99-
fixture.SetupHandler(t, resURL, "PUT", updateReq, "", 202)
99+
fixture.SetupHandler(t, resURL, "PUT", UpdateReq, "", 202)
100100

101101
opts := UpdateOpts{
102102
Values: map[string]interface{}{
@@ -120,7 +120,7 @@ func TestDelete(t *testing.T) {
120120
func TestListInstances(t *testing.T) {
121121
th.SetupHTTP()
122122
defer th.TeardownHTTP()
123-
fixture.SetupHandler(t, resURL+"/instances", "GET", "", listInstancesJSON, 200)
123+
fixture.SetupHandler(t, resURL+"/instances", "GET", "", ListInstancesJSON, 200)
124124

125125
expectedInstance := instances.Instance{
126126
ID: "d4603f69-ec7e-4e9b-803f-600b9205576f",
@@ -148,7 +148,7 @@ func TestListInstances(t *testing.T) {
148148
func TestListDSParams(t *testing.T) {
149149
th.SetupHTTP()
150150
defer th.TeardownHTTP()
151-
fixture.SetupHandler(t, dsParamListURL, "GET", "", listParamsJSON, 200)
151+
fixture.SetupHandler(t, dsParamListURL, "GET", "", ListParamsJSON, 200)
152152

153153
pages := 0
154154
err := ListDatastoreParams(fake.ServiceClient(), dsID, versionID).EachPage(func(page pagination.Page) (bool, error) {
@@ -178,7 +178,7 @@ func TestListDSParams(t *testing.T) {
178178
func TestGetDSParam(t *testing.T) {
179179
th.SetupHTTP()
180180
defer th.TeardownHTTP()
181-
fixture.SetupHandler(t, dsParamGetURL, "GET", "", getParamJSON, 200)
181+
fixture.SetupHandler(t, dsParamGetURL, "GET", "", GetParamJSON, 200)
182182

183183
param, err := GetDatastoreParam(fake.ServiceClient(), dsID, versionID, paramID).Extract()
184184
th.AssertNoErr(t, err)
@@ -193,7 +193,7 @@ func TestGetDSParam(t *testing.T) {
193193
func TestListGlobalParams(t *testing.T) {
194194
th.SetupHTTP()
195195
defer th.TeardownHTTP()
196-
fixture.SetupHandler(t, globalParamListURL, "GET", "", listParamsJSON, 200)
196+
fixture.SetupHandler(t, globalParamListURL, "GET", "", ListParamsJSON, 200)
197197

198198
pages := 0
199199
err := ListGlobalParams(fake.ServiceClient(), versionID).EachPage(func(page pagination.Page) (bool, error) {
@@ -223,7 +223,7 @@ func TestListGlobalParams(t *testing.T) {
223223
func TestGetGlobalParam(t *testing.T) {
224224
th.SetupHTTP()
225225
defer th.TeardownHTTP()
226-
fixture.SetupHandler(t, globalParamGetURL, "GET", "", getParamJSON, 200)
226+
fixture.SetupHandler(t, globalParamGetURL, "GET", "", GetParamJSON, 200)
227227

228228
param, err := GetGlobalParam(fake.ServiceClient(), versionID, paramID).Extract()
229229
th.AssertNoErr(t, err)

0 commit comments

Comments
 (0)