revert cdn files to master versions
diff --git a/openstack/cdn/v1/services/requests_test.go b/openstack/cdn/v1/services/requests_test.go
index c5a0405..59e826f 100644
--- a/openstack/cdn/v1/services/requests_test.go
+++ b/openstack/cdn/v1/services/requests_test.go
@@ -298,26 +298,51 @@
HandleUpdateCDNServiceSuccessfully(t)
expected := "https://www.poppycdn.io/v1.0/services/96737ae3-cfc1-4c72-be88-5d0e7cc9a3f0"
- updateOpts := UpdateOpts{
- Replacement{
- Value: OriginList{
- Origin{
- Origin: "44.33.22.11",
- Port: 80,
- SSL: false,
- },
- },
- Index: 0,
+ ops := UpdateOpts{
+ // Append a single Domain
+ Append{Value: Domain{Domain: "appended.mocksite4.com"}},
+ // Insert a single Domain
+ Insertion{
+ Index: 4,
+ Value: Domain{Domain: "inserted.mocksite4.com"},
},
+ // Bulk addition
Append{
Value: DomainList{
- Domain{
- Domain: "appended.mocksite4.com",
- },
+ Domain{Domain: "bulkadded1.mocksite4.com"},
+ Domain{Domain: "bulkadded2.mocksite4.com"},
},
},
+ // Replace a single Origin
+ Replacement{
+ Index: 2,
+ Value: Origin{Origin: "44.33.22.11", Port: 80, SSL: false},
+ },
+ // Bulk replace Origins
+ Replacement{
+ Index: 0, // Ignored
+ Value: OriginList{
+ Origin{Origin: "44.33.22.11", Port: 80, SSL: false},
+ Origin{Origin: "55.44.33.22", Port: 443, SSL: true},
+ },
+ },
+ // Remove a single CacheRule
+ Removal{
+ Index: 8,
+ Path: PathCaching,
+ },
+ // Bulk removal
+ Removal{
+ All: true,
+ Path: PathCaching,
+ },
+ // Service name replacement
+ NameReplacement{
+ NewName: "differentServiceName",
+ },
}
- actual, err := Update(fake.ServiceClient(), "96737ae3-cfc1-4c72-be88-5d0e7cc9a3f0", updateOpts).Extract()
+
+ actual, err := Update(fake.ServiceClient(), "96737ae3-cfc1-4c72-be88-5d0e7cc9a3f0", ops).Extract()
th.AssertNoErr(t, err)
th.AssertEquals(t, expected, actual)
}