Documentation ¶
Overview ¶
recordsets unit tests
Index ¶
Constants ¶
const CreateRecordSetRequest = `` /* 153-byte string literal not displayed */
CreateRecordSetRequest is a sample request to create a resource record.
const CreateRecordSetResponse = `` /* 652-byte string literal not displayed */
CreateRecordSetResponse is a sample response to a create request.
const DeleteRecordSetResponse = `` /* 661-byte string literal not displayed */
DeleteRecordSetResponse is a sample response to a delete request.
const GetOutput = `` /* 610-byte string literal not displayed */
GetOutput is a sample response to a Get call.
const ListByZoneOutput = `` /* 1900-byte string literal not displayed */
ListByZoneOutput is a sample response to a ListByZone call.
const ListByZoneOutputLimited = `` /* 1030-byte string literal not displayed */
ListByZoneOutputLimited is a sample response to a ListByZone call with a requested limit.
const NextPageRequest = `` /* 269-byte string literal not displayed */
NextPageRequest is a sample request to test pagination.
const UpdateRecordSetRequest = `
{
"description" : "Updated description",
"ttl" : null,
"records" : [
"10.1.0.2",
"10.1.0.3"
]
}
`
UpdateRecordSetRequest is a sample request to update a record set.
const UpdateRecordSetResponse = `` /* 661-byte string literal not displayed */
UpdateRecordSetResponse is a sample response to an update request.
Variables ¶
var CreatedRecordSet = FirstRecordSet
CreatedRecordSet is the expected created resource record.
var ExpectedRecordSetSlice = []recordsets.RecordSet{FirstRecordSet, SecondRecordSet}
ExpectedRecordSetSlice is the slice of results that should be parsed from ListByZoneOutput, in the expected order.
var ExpectedRecordSetSliceLimited = []recordsets.RecordSet{SecondRecordSet}
ExpectedRecordSetSliceLimited is the slice of limited results that should be parsed from ListByZoneOutput.
var FirstRecordSet = recordsets.RecordSet{ ID: "f7b10e9b-0cae-4a91-b162-562bc6096648", Description: "This is an example record set.", Records: []string{"10.1.0.2"}, TTL: 3600, Name: "example.org.", ProjectID: "4335d1f0-f793-11e2-b778-0800200c9a66", ZoneID: "2150b1bf-dee2-4221-9d85-11f7886fb15f", ZoneName: "example.com.", CreatedAt: "2014-10-24T19:59:44.000000", Type: "A", Status: "PENDING", Links: recordsets.Link{ Self: "https://127.0.0.1:9001/v2/zones/2150b1bf-dee2-4221-9d85-11f7886fb15f/recordsets/f7b10e9b-0cae-4a91-b162-562bc6096648", }, }
var FirstRecordSetCreatedAt, _ = time.Parse(gophercloud.RFC3339MilliNoZ, "2014-10-24T19:59:44.000000")
FirstRecordSet is the first result in ListByZoneOutput
var SecondRecordSet = recordsets.RecordSet{ ID: "7423aeaf-b354-4bd7-8aba-2e831567b478", Description: "This is another example record set.", UpdatedAt: "2017-03-04T14:29:07.000000", Records: []string{"10.1.0.3", "10.1.0.4"}, TTL: 3600, Name: "foo.example.org.", ProjectID: "4335d1f0-f793-11e2-b778-0800200c9a66", ZoneID: "2150b1bf-dee2-4221-9d85-11f7886fb15f", ZoneName: "example.com.", CreatedAt: "2014-10-24T19:59:44.000000", Type: "A", Status: "PENDING", Links: recordsets.Link{ Self: "https://127.0.0.1:9001/v2/zones/2150b1bf-dee2-4221-9d85-11f7886fb15f/recordsets/7423aeaf-b354-4bd7-8aba-2e831567b478", }, }
SecondRecordSet is the first result in ListByZoneOutput
Functions ¶
func HandleCreateSuccessfully ¶
HandleZoneCreationSuccessfully configures the test server to respond to a Create request.
func HandleDeleteSuccessfully ¶
HandleDeleteSuccessfully configures the test server to respond to an Delete request.
func HandleGetSuccessfully ¶
HandleGetSuccessfully configures the test server to respond to a Get request.
func HandleListByZoneSuccessfully ¶
HandleListByZoneSuccessfully configures the test server to respond to a ListByZone request.
func HandleUpdateSuccessfully ¶
HandleUpdateSuccessfully configures the test server to respond to an Update request.
Types ¶
This section is empty.