diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/CHANGELOG.md b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/CHANGELOG.md index 2c6aff4c4ac7..ec16aa120382 100644 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/CHANGELOG.md +++ b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/CHANGELOG.md @@ -1,5 +1,9 @@ # Release History +## 0.5.1 (2022-05-13) +### Other Changes + + ## 0.5.0 (2022-04-18) ### Breaking Changes diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/autorest.md b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/autorest.md index 7395e001f5a7..ceba57e9e28b 100644 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/autorest.md +++ b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/autorest.md @@ -5,8 +5,8 @@ ``` yaml azure-arm: true require: -- https://github.com/Azure/azure-rest-api-specs/blob/f92aaf88f4c9d1ffb9a014eba196d887a9288c3a/specification/recoveryservicesbackup/resource-manager/readme.md -- https://github.com/Azure/azure-rest-api-specs/blob/f92aaf88f4c9d1ffb9a014eba196d887a9288c3a/specification/recoveryservicesbackup/resource-manager/readme.go.md +- /mnt/vss/_work/1/s/azure-rest-api-specs/specification/recoveryservicesbackup/resource-manager/readme.md +- /mnt/vss/_work/1/s/azure-rest-api-specs/specification/recoveryservicesbackup/resource-manager/readme.go.md license-header: MICROSOFT_MIT_NO_VERSION -module-version: 0.5.0 +module-version: 0.5.1 ``` \ No newline at end of file diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/go.mod b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/go.mod index 49261b78dc10..1e2f26d946c2 100644 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/go.mod +++ b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/go.mod @@ -2,20 +2,10 @@ module github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/ar go 1.18 -require ( - github.com/Azure/azure-sdk-for-go/sdk/azcore v0.23.0 - github.com/Azure/azure-sdk-for-go/sdk/azidentity v0.14.0 -) +require github.com/Azure/azure-sdk-for-go/sdk/azcore v0.23.0 require ( github.com/Azure/azure-sdk-for-go/sdk/internal v0.9.1 // indirect - github.com/AzureAD/microsoft-authentication-library-for-go v0.4.0 // indirect - github.com/golang-jwt/jwt v3.2.1+incompatible // indirect - github.com/google/uuid v1.1.1 // indirect - github.com/kylelemons/godebug v1.1.0 // indirect - github.com/pkg/browser v0.0.0-20210115035449-ce105d075bb4 // indirect - golang.org/x/crypto v0.0.0-20201016220609-9e8e0b390897 // indirect - golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f // indirect - golang.org/x/sys v0.0.0-20211019181941-9d821ace8654 // indirect - golang.org/x/text v0.3.7 // indirect + golang.org/x/net v0.0.0-20210610132358-84b48f89b13b // indirect + golang.org/x/text v0.3.6 // indirect ) diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/go.sum b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/go.sum index 56d1c32628ae..a7eaa30576c1 100644 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/go.sum +++ b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/go.sum @@ -1,26 +1,11 @@ github.com/Azure/azure-sdk-for-go/sdk/azcore v0.23.0 h1:D7l5jspkc4kwBYRWoZE4DQnu6LVpLwDsMZjBKS4wZLQ= github.com/Azure/azure-sdk-for-go/sdk/azcore v0.23.0/go.mod h1:w5pDIZuawUmY3Bj4tVx3Xb8KS96ToB0j315w9rqpAg0= -github.com/Azure/azure-sdk-for-go/sdk/azidentity v0.14.0 h1:NVS/4LOQfkBpk+B1VopIzv1ptmYeEskA8w/3K/w7vjo= -github.com/Azure/azure-sdk-for-go/sdk/azidentity v0.14.0/go.mod h1:RG0cZndeZM17StwohYclmcXSr4oOJ8b1I5hB8llIc6Y= github.com/Azure/azure-sdk-for-go/sdk/internal v0.9.1 h1:sLZ/Y+P/5RRtsXWylBjB5lkgixYfm0MQPiwrSX//JSo= github.com/Azure/azure-sdk-for-go/sdk/internal v0.9.1/go.mod h1:KLF4gFr6DcKFZwSuH8w8yEK6DpFl3LP5rhdvAb7Yz5I= -github.com/AzureAD/microsoft-authentication-library-for-go v0.4.0 h1:WVsrXCnHlDDX8ls+tootqRE87/hL9S/g4ewig9RsD/c= -github.com/AzureAD/microsoft-authentication-library-for-go v0.4.0/go.mod h1:Vt9sXTKwMyGcOxSmLDMnGPgqsUg7m8pe215qMLrDXw4= +github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= -github.com/dnaeon/go-vcr v1.1.0 h1:ReYa/UBrRyQdant9B4fNHGoCNKw6qh6P0fsdGmZpR7c= github.com/dnaeon/go-vcr v1.1.0/go.mod h1:M7tiix8f0r6mKKJ3Yq/kqU1OYf3MnfmBWVbPx/yU9ko= -github.com/golang-jwt/jwt v3.2.1+incompatible h1:73Z+4BJcrTC+KczS6WvTPvRGOp1WmfEP4Q1lOd9Z/+c= -github.com/golang-jwt/jwt v3.2.1+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= -github.com/golang-jwt/jwt/v4 v4.2.0 h1:besgBTC8w8HjP6NzQdxwKH9Z5oQMZ24ThTrHp3cZ8eU= -github.com/google/uuid v1.1.1 h1:Gkbcsh/GbpXz7lPftLA3P6TYMwjCLYm83jiFQZF/3gY= -github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= -github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/modocache/gover v0.0.0-20171022184752-b58185e213c5/go.mod h1:caMODM3PzxT8aQXRPkAt8xlV/e7d7w8GM5g0fa5F0D8= -github.com/montanaflynn/stats v0.6.6/go.mod h1:etXPPgVO6n31NxCd9KQUMvCM+ve0ruNzt6R8Bnaayow= -github.com/pkg/browser v0.0.0-20210115035449-ce105d075bb4 h1:Qj1ukM4GlMWXNdMBuXcXfz/Kw9s1qm0CLY32QxuSImI= -github.com/pkg/browser v0.0.0-20210115035449-ce105d075bb4/go.mod h1:N6UoU20jOqggOuDwUaBQpluzLNDqif3kq9z2wpdYEfQ= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= @@ -28,26 +13,20 @@ github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5Cc github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20201016220609-9e8e0b390897 h1:pLI5jrR7OSLijeIDcmRxNmw2api+jEfxLoykJVice/E= -golang.org/x/crypto v0.0.0-20201016220609-9e8e0b390897/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20201010224723-4f7140c49acb/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= -golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f h1:OfiFi4JbukWwe3lzw+xunroH1mnC1e2Gy5cxNJApiSY= -golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +golang.org/x/net v0.0.0-20210610132358-84b48f89b13b h1:k+E048sYJHyVnsr1GDrRZWQ32D2C7lWs9JRc0bel53A= +golang.org/x/net v0.0.0-20210610132358-84b48f89b13b/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20211019181941-9d821ace8654 h1:id054HUawV2/6IGm2IV8KZQjqtwAOo2CYlOToYqa0d0= -golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk= -golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= +golang.org/x/text v0.3.6 h1:aRYxNxv6iGQlyVaZmk6ZgYEDa+Jg18DxebPSrd6bg1M= +golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= +gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c h1:dUUwHk2QECo/6vqA44rthZ8ie2QXMNeKRTHCNY2nXvo= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b h1:h8qDotaEPuJATrMmW04NCwg7v22aHH28wwpauUhK9Oo= diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupengines_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupengines_client_test.go deleted file mode 100644 index 46757d7cc4c1..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupengines_client_test.go +++ /dev/null @@ -1,71 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Dpm/BackupEngines_List.json -func ExampleBackupEnginesClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupEnginesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - &armrecoveryservicesbackup.BackupEnginesClientListOptions{Filter: nil, - SkipToken: nil, - }) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Dpm/BackupEngines_Get.json -func ExampleBackupEnginesClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupEnginesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - &armrecoveryservicesbackup.BackupEnginesClientGetOptions{Filter: nil, - SkipToken: nil, - }) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupjobs_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupjobs_client_test.go deleted file mode 100644 index e06ebdf3270a..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupjobs_client_test.go +++ /dev/null @@ -1,46 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/ListJobs.json -func ExampleBackupJobsClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupJobsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - &armrecoveryservicesbackup.BackupJobsClientListOptions{Filter: nil, - SkipToken: nil, - }) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupoperationresults_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupoperationresults_client_test.go deleted file mode 100644 index e307f67a6ac1..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupoperationresults_client_test.go +++ /dev/null @@ -1,38 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/ProtectedItem_Delete_OperationResult.json -func ExampleBackupOperationResultsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupOperationResultsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Get(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupoperationstatuses_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupoperationstatuses_client_test.go deleted file mode 100644 index 3151f94e2013..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupoperationstatuses_client_test.go +++ /dev/null @@ -1,40 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/ProtectedItem_Delete_OperationStatus.json -func ExampleBackupOperationStatusesClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupOperationStatusesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backuppolicies_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backuppolicies_client_test.go deleted file mode 100644 index 3c10cf2daeed..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backuppolicies_client_test.go +++ /dev/null @@ -1,45 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/BackupPolicies_List.json -func ExampleBackupPoliciesClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupPoliciesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - &armrecoveryservicesbackup.BackupPoliciesClientListOptions{Filter: to.Ptr("")}) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotectableitems_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotectableitems_client_test.go deleted file mode 100644 index 1ddaae3b487a..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotectableitems_client_test.go +++ /dev/null @@ -1,47 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/BackupProtectableItems_List.json -func ExampleBackupProtectableItemsClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupProtectableItemsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - &armrecoveryservicesbackup.BackupProtectableItemsClientListOptions{Filter: to.Ptr(""), - SkipToken: nil, - }) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotecteditems_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotecteditems_client_test.go deleted file mode 100644 index e1bad1e64e73..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotecteditems_client_test.go +++ /dev/null @@ -1,47 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/BackupProtectedItems_List.json -func ExampleBackupProtectedItemsClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupProtectedItemsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - &armrecoveryservicesbackup.BackupProtectedItemsClientListOptions{Filter: to.Ptr(""), - SkipToken: nil, - }) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotectioncontainers_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotectioncontainers_client_test.go deleted file mode 100644 index 071998c5638f..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotectioncontainers_client_test.go +++ /dev/null @@ -1,45 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureStorage/ProtectionContainers_List.json -func ExampleBackupProtectionContainersClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupProtectionContainersClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - &armrecoveryservicesbackup.BackupProtectionContainersClientListOptions{Filter: to.Ptr("")}) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotectionintent_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotectionintent_client_test.go deleted file mode 100644 index 4b639f45a876..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupprotectionintent_client_test.go +++ /dev/null @@ -1,46 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureWorkload/BackupProtectionIntent_List.json -func ExampleBackupProtectionIntentClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupProtectionIntentClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - &armrecoveryservicesbackup.BackupProtectionIntentClientListOptions{Filter: nil, - SkipToken: nil, - }) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupresourceencryptionconfigs_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupresourceencryptionconfigs_client_test.go deleted file mode 100644 index fb5ca6bcd6da..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupresourceencryptionconfigs_client_test.go +++ /dev/null @@ -1,68 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/BackupResourceEncryptionConfig_Get.json -func ExampleBackupResourceEncryptionConfigsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupResourceEncryptionConfigsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/BackupResourceEncryptionConfig_Put.json -func ExampleBackupResourceEncryptionConfigsClient_Update() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupResourceEncryptionConfigsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Update(ctx, - "", - "", - armrecoveryservicesbackup.BackupResourceEncryptionConfigResource{ - Properties: &armrecoveryservicesbackup.BackupResourceEncryptionConfig{ - EncryptionAtRestType: to.Ptr(armrecoveryservicesbackup.EncryptionAtRestTypeCustomerManaged), - InfrastructureEncryptionState: to.Ptr(armrecoveryservicesbackup.InfrastructureEncryptionState("true")), - KeyURI: to.Ptr(""), - SubscriptionID: to.Ptr(""), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupresourcestorageconfigsnoncrr_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupresourcestorageconfigsnoncrr_client_test.go deleted file mode 100644 index 0bd4f117e16b..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupresourcestorageconfigsnoncrr_client_test.go +++ /dev/null @@ -1,94 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/BackupStorageConfig_Get.json -func ExampleBackupResourceStorageConfigsNonCRRClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupResourceStorageConfigsNonCRRClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/BackupStorageConfig_Put.json -func ExampleBackupResourceStorageConfigsNonCRRClient_Update() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupResourceStorageConfigsNonCRRClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Update(ctx, - "", - "", - armrecoveryservicesbackup.BackupResourceConfigResource{ - Properties: &armrecoveryservicesbackup.BackupResourceConfig{ - StorageType: to.Ptr(armrecoveryservicesbackup.StorageTypeLocallyRedundant), - StorageTypeState: to.Ptr(armrecoveryservicesbackup.StorageTypeStateUnlocked), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/BackupStorageConfig_Patch.json -func ExampleBackupResourceStorageConfigsNonCRRClient_Patch() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupResourceStorageConfigsNonCRRClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Patch(ctx, - "", - "", - armrecoveryservicesbackup.BackupResourceConfigResource{ - Properties: &armrecoveryservicesbackup.BackupResourceConfig{ - StorageType: to.Ptr(armrecoveryservicesbackup.StorageTypeLocallyRedundant), - StorageTypeState: to.Ptr(armrecoveryservicesbackup.StorageTypeStateUnlocked), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupresourcevaultconfigs_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupresourcevaultconfigs_client_test.go deleted file mode 100644 index 6f1ba883dc89..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupresourcevaultconfigs_client_test.go +++ /dev/null @@ -1,95 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/BackupResourceVaultConfigs_Get.json -func ExampleBackupResourceVaultConfigsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupResourceVaultConfigsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/BackupResourceVaultConfigs_Patch.json -func ExampleBackupResourceVaultConfigsClient_Update() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupResourceVaultConfigsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Update(ctx, - "", - "", - armrecoveryservicesbackup.BackupResourceVaultConfigResource{ - Properties: &armrecoveryservicesbackup.BackupResourceVaultConfig{ - EnhancedSecurityState: to.Ptr(armrecoveryservicesbackup.EnhancedSecurityStateEnabled), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/BackupResourceVaultConfigs_Put.json -func ExampleBackupResourceVaultConfigsClient_Put() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupResourceVaultConfigsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Put(ctx, - "", - "", - armrecoveryservicesbackup.BackupResourceVaultConfigResource{ - Properties: &armrecoveryservicesbackup.BackupResourceVaultConfig{ - EnhancedSecurityState: to.Ptr(armrecoveryservicesbackup.EnhancedSecurityStateEnabled), - SoftDeleteFeatureState: to.Ptr(armrecoveryservicesbackup.SoftDeleteFeatureStateEnabled), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backups_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backups_client_test.go deleted file mode 100644 index 3b997a7361d0..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backups_client_test.go +++ /dev/null @@ -1,46 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/TriggerBackup_Post.json -func ExampleBackupsClient_Trigger() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Trigger(ctx, - "", - "", - "", - "", - "", - armrecoveryservicesbackup.BackupRequestResource{ - Properties: &armrecoveryservicesbackup.IaasVMBackupRequest{ - ObjectType: to.Ptr(""), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupstatus_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupstatus_client_test.go deleted file mode 100644 index 9ab0a14571a2..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupstatus_client_test.go +++ /dev/null @@ -1,43 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/GetBackupStatus.json -func ExampleBackupStatusClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupStatusClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - armrecoveryservicesbackup.BackupStatusRequest{ - ResourceID: to.Ptr(""), - ResourceType: to.Ptr(armrecoveryservicesbackup.DataSourceTypeVM), - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupusagesummaries_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupusagesummaries_client_test.go deleted file mode 100644 index e58a4084ecbf..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupusagesummaries_client_test.go +++ /dev/null @@ -1,47 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/BackupProtectionContainers_UsageSummary_Get.json -func ExampleBackupUsageSummariesClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupUsageSummariesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - &armrecoveryservicesbackup.BackupUsageSummariesClientListOptions{Filter: to.Ptr(""), - SkipToken: nil, - }) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupworkloaditems_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupworkloaditems_client_test.go deleted file mode 100644 index a636ea6bc037..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_backupworkloaditems_client_test.go +++ /dev/null @@ -1,49 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureWorkload/BackupWorkloadItems_List.json -func ExampleBackupWorkloadItemsClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBackupWorkloadItemsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - "", - "", - &armrecoveryservicesbackup.BackupWorkloadItemsClientListOptions{Filter: to.Ptr(""), - SkipToken: nil, - }) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_bmspreparedatamoveoperationresult_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_bmspreparedatamoveoperationresult_client_test.go deleted file mode 100644 index 39efdf42bc2e..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_bmspreparedatamoveoperationresult_client_test.go +++ /dev/null @@ -1,40 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/BackupDataMove/PrepareDataMoveOperationResult_Get.json -func ExampleBMSPrepareDataMoveOperationResultClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewBMSPrepareDataMoveOperationResultClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_exportjobsoperationresults_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_exportjobsoperationresults_client_test.go deleted file mode 100644 index e15d9486ae9b..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_exportjobsoperationresults_client_test.go +++ /dev/null @@ -1,40 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/ExportJobsOperationResult.json -func ExampleExportJobsOperationResultsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewExportJobsOperationResultsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_featuresupport_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_featuresupport_client_test.go deleted file mode 100644 index a1f7f312580a..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_featuresupport_client_test.go +++ /dev/null @@ -1,44 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/BackupFeature_Validate.json -func ExampleFeatureSupportClient_Validate() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewFeatureSupportClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Validate(ctx, - "", - &armrecoveryservicesbackup.AzureVMResourceFeatureSupportRequest{ - FeatureType: to.Ptr(""), - VMSize: to.Ptr(""), - VMSKU: to.Ptr(""), - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_itemlevelrecoveryconnections_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_itemlevelrecoveryconnections_client_test.go deleted file mode 100644 index e91a2d998245..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_itemlevelrecoveryconnections_client_test.go +++ /dev/null @@ -1,75 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/Provision_Ilr.json -func ExampleItemLevelRecoveryConnectionsClient_Provision() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewItemLevelRecoveryConnectionsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Provision(ctx, - "", - "", - "", - "", - "", - "", - armrecoveryservicesbackup.ILRRequestResource{ - Properties: &armrecoveryservicesbackup.IaasVMILRRegistrationRequest{ - ObjectType: to.Ptr(""), - InitiatorName: to.Ptr(""), - RecoveryPointID: to.Ptr(""), - RenewExistingRegistration: to.Ptr(true), - VirtualMachineID: to.Ptr(""), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/Revoke_Ilr.json -func ExampleItemLevelRecoveryConnectionsClient_Revoke() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewItemLevelRecoveryConnectionsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Revoke(ctx, - "", - "", - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_jobcancellations_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_jobcancellations_client_test.go deleted file mode 100644 index 1be8af01a094..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_jobcancellations_client_test.go +++ /dev/null @@ -1,38 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/TriggerCancelJob.json -func ExampleJobCancellationsClient_Trigger() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewJobCancellationsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Trigger(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_jobdetails_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_jobdetails_client_test.go deleted file mode 100644 index 145b14e5f2cf..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_jobdetails_client_test.go +++ /dev/null @@ -1,40 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/GetJobDetails.json -func ExampleJobDetailsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewJobDetailsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_joboperationresults_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_joboperationresults_client_test.go deleted file mode 100644 index fd6c61f2372e..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_joboperationresults_client_test.go +++ /dev/null @@ -1,39 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/CancelJobOperationResult.json -func ExampleJobOperationResultsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewJobOperationResultsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Get(ctx, - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_jobs_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_jobs_client_test.go deleted file mode 100644 index 99a652547778..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_jobs_client_test.go +++ /dev/null @@ -1,37 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/TriggerExportJobs.json -func ExampleJobsClient_Export() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewJobsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Export(ctx, - "", - "", - &armrecoveryservicesbackup.JobsClientExportOptions{Filter: nil}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_operation_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_operation_client_test.go deleted file mode 100644 index f66bd5df1486..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_operation_client_test.go +++ /dev/null @@ -1,60 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ValidateOperation_RestoreDisk.json -func ExampleOperationClient_Validate() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewOperationClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Validate(ctx, - "", - "", - &armrecoveryservicesbackup.ValidateIaasVMRestoreOperationRequest{ - ObjectType: to.Ptr(""), - RestoreRequest: &armrecoveryservicesbackup.IaasVMRestoreRequest{ - ObjectType: to.Ptr(""), - CreateNewCloudService: to.Ptr(true), - EncryptionDetails: &armrecoveryservicesbackup.EncryptionDetails{ - EncryptionEnabled: to.Ptr(false), - }, - IdentityInfo: &armrecoveryservicesbackup.IdentityInfo{ - IsSystemAssignedIdentity: to.Ptr(false), - ManagedIdentityResourceID: to.Ptr(""), - }, - OriginalStorageAccountOption: to.Ptr(false), - RecoveryPointID: to.Ptr(""), - RecoveryType: to.Ptr(armrecoveryservicesbackup.RecoveryTypeRestoreDisks), - Region: to.Ptr(""), - SourceResourceID: to.Ptr(""), - StorageAccountID: to.Ptr(""), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_operations_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_operations_client_test.go deleted file mode 100644 index afa4a0349009..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_operations_client_test.go +++ /dev/null @@ -1,42 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/ListOperations.json -func ExampleOperationsClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewOperationsClient(cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager(nil) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_privateendpoint_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_privateendpoint_client_test.go deleted file mode 100644 index 1c6ee56b48a7..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_privateendpoint_client_test.go +++ /dev/null @@ -1,41 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/PrivateEndpointConnection/GetPrivateEndpointConnectionOperationStatus.json -func ExamplePrivateEndpointClient_GetOperationStatus() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewPrivateEndpointClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.GetOperationStatus(ctx, - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_privateendpointconnection_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_privateendpointconnection_client_test.go deleted file mode 100644 index e0d6224f8a91..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_privateendpointconnection_client_test.go +++ /dev/null @@ -1,107 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "time" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/PrivateEndpointConnection/GetPrivateEndpointConnection.json -func ExamplePrivateEndpointConnectionClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewPrivateEndpointConnectionClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/PrivateEndpointConnection/PutPrivateEndpointConnection.json -func ExamplePrivateEndpointConnectionClient_BeginPut() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewPrivateEndpointConnectionClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - poller, err := client.BeginPut(ctx, - "", - "", - "", - armrecoveryservicesbackup.PrivateEndpointConnectionResource{ - Properties: &armrecoveryservicesbackup.PrivateEndpointConnection{ - PrivateEndpoint: &armrecoveryservicesbackup.PrivateEndpoint{ - ID: to.Ptr(""), - }, - PrivateLinkServiceConnectionState: &armrecoveryservicesbackup.PrivateLinkServiceConnectionState{ - Description: to.Ptr(""), - Status: to.Ptr(armrecoveryservicesbackup.PrivateEndpointConnectionStatusApproved), - }, - ProvisioningState: to.Ptr(armrecoveryservicesbackup.ProvisioningStateSucceeded), - }, - }, - &armrecoveryservicesbackup.PrivateEndpointConnectionClientBeginPutOptions{ResumeToken: ""}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - res, err := poller.PollUntilDone(ctx, 30*time.Second) - if err != nil { - log.Fatalf("failed to pull the result: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/PrivateEndpointConnection/DeletePrivateEndpointConnection.json -func ExamplePrivateEndpointConnectionClient_BeginDelete() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewPrivateEndpointConnectionClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - poller, err := client.BeginDelete(ctx, - "", - "", - "", - &armrecoveryservicesbackup.PrivateEndpointConnectionClientBeginDeleteOptions{ResumeToken: ""}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - _, err = poller.PollUntilDone(ctx, 30*time.Second) - if err != nil { - log.Fatalf("failed to pull the result: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectablecontainers_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectablecontainers_client_test.go deleted file mode 100644 index 5200f0263307..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectablecontainers_client_test.go +++ /dev/null @@ -1,46 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureStorage/ProtectableContainers_List.json -func ExampleProtectableContainersClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectableContainersClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - "", - &armrecoveryservicesbackup.ProtectableContainersClientListOptions{Filter: to.Ptr("")}) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protecteditemoperationresults_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protecteditemoperationresults_client_test.go deleted file mode 100644 index a03bd4793102..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protecteditemoperationresults_client_test.go +++ /dev/null @@ -1,43 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ProtectedItemOperationResults.json -func ExampleProtectedItemOperationResultsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectedItemOperationResultsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protecteditemoperationstatuses_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protecteditemoperationstatuses_client_test.go deleted file mode 100644 index 78ca51a6b66b..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protecteditemoperationstatuses_client_test.go +++ /dev/null @@ -1,43 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ProtectedItemOperationStatus.json -func ExampleProtectedItemOperationStatusesClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectedItemOperationStatusesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protecteditems_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protecteditems_client_test.go deleted file mode 100644 index c10afce52567..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protecteditems_client_test.go +++ /dev/null @@ -1,98 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ClassicCompute_ProtectedItem_Get.json -func ExampleProtectedItemsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectedItemsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - "", - "", - &armrecoveryservicesbackup.ProtectedItemsClientGetOptions{Filter: nil}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ConfigureProtection.json -func ExampleProtectedItemsClient_CreateOrUpdate() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectedItemsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.CreateOrUpdate(ctx, - "", - "", - "", - "", - "", - armrecoveryservicesbackup.ProtectedItemResource{ - Properties: &armrecoveryservicesbackup.AzureIaaSComputeVMProtectedItem{ - PolicyID: to.Ptr(""), - ProtectedItemType: to.Ptr(""), - SourceResourceID: to.Ptr(""), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/ProtectedItem_Delete.json -func ExampleProtectedItemsClient_Delete() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectedItemsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Delete(ctx, - "", - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectioncontaineroperationresults_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectioncontaineroperationresults_client_test.go deleted file mode 100644 index dd75551826f0..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectioncontaineroperationresults_client_test.go +++ /dev/null @@ -1,42 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureStorage/ProtectionContainers_Inquire_Result.json -func ExampleProtectionContainerOperationResultsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionContainerOperationResultsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectioncontainerrefreshoperationresults_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectioncontainerrefreshoperationresults_client_test.go deleted file mode 100644 index 8bc973aa4e62..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectioncontainerrefreshoperationresults_client_test.go +++ /dev/null @@ -1,39 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/RefreshContainers_OperationResults.json -func ExampleProtectionContainerRefreshOperationResultsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionContainerRefreshOperationResultsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Get(ctx, - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectioncontainers_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectioncontainers_client_test.go deleted file mode 100644 index d2bda9438423..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectioncontainers_client_test.go +++ /dev/null @@ -1,140 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureWorkload/ProtectionContainers_Get.json -func ExampleProtectionContainersClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionContainersClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureStorage/ProtectionContainers_Register.json -func ExampleProtectionContainersClient_Register() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionContainersClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Register(ctx, - "", - "", - "", - "", - armrecoveryservicesbackup.ProtectionContainerResource{ - Properties: &armrecoveryservicesbackup.AzureStorageContainer{ - BackupManagementType: to.Ptr(armrecoveryservicesbackup.BackupManagementTypeAzureStorage), - ContainerType: to.Ptr(armrecoveryservicesbackup.ContainerTypeStorageContainer), - FriendlyName: to.Ptr(""), - AcquireStorageAccountLock: to.Ptr(armrecoveryservicesbackup.AcquireStorageAccountLockAcquire), - SourceResourceID: to.Ptr(""), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureWorkload/ProtectionContainers_Unregister.json -func ExampleProtectionContainersClient_Unregister() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionContainersClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Unregister(ctx, - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureStorage/ProtectionContainers_Inquire.json -func ExampleProtectionContainersClient_Inquire() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionContainersClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Inquire(ctx, - "", - "", - "", - "", - &armrecoveryservicesbackup.ProtectionContainersClientInquireOptions{Filter: nil}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/RefreshContainers.json -func ExampleProtectionContainersClient_Refresh() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionContainersClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Refresh(ctx, - "", - "", - "", - &armrecoveryservicesbackup.ProtectionContainersClientRefreshOptions{Filter: nil}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionintent_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionintent_client_test.go deleted file mode 100644 index d6f5e87dffb7..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionintent_client_test.go +++ /dev/null @@ -1,122 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ProtectionIntent_Validate.json -func ExampleProtectionIntentClient_Validate() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionIntentClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Validate(ctx, - "", - armrecoveryservicesbackup.PreValidateEnableBackupRequest{ - Properties: to.Ptr(""), - ResourceID: to.Ptr(""), - ResourceType: to.Ptr(armrecoveryservicesbackup.DataSourceTypeVM), - VaultID: to.Ptr(""), - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureWorkload/BackupProtectionIntent_Get.json -func ExampleProtectionIntentClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionIntentClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ProtectionIntent_CreateOrUpdate.json -func ExampleProtectionIntentClient_CreateOrUpdate() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionIntentClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.CreateOrUpdate(ctx, - "", - "", - "", - "", - armrecoveryservicesbackup.ProtectionIntentResource{ - Properties: &armrecoveryservicesbackup.AzureResourceProtectionIntent{ - PolicyID: to.Ptr(""), - ProtectionIntentItemType: to.Ptr(armrecoveryservicesbackup.ProtectionIntentItemTypeAzureResourceItem), - SourceResourceID: to.Ptr(""), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureWorkload/BackupProtectionIntent_Delete.json -func ExampleProtectionIntentClient_Delete() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionIntentClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Delete(ctx, - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionpolicies_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionpolicies_client_test.go deleted file mode 100644 index 272735cb3e3b..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionpolicies_client_test.go +++ /dev/null @@ -1,157 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "time" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/V2Policy/v2-Get-Policy.json -func ExampleProtectionPoliciesClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionPoliciesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureStorage/ProtectionPolicies_CreateOrUpdate_Daily.json -func ExampleProtectionPoliciesClient_CreateOrUpdate() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionPoliciesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.CreateOrUpdate(ctx, - "", - "", - "", - armrecoveryservicesbackup.ProtectionPolicyResource{ - Properties: &armrecoveryservicesbackup.AzureFileShareProtectionPolicy{ - BackupManagementType: to.Ptr(""), - RetentionPolicy: &armrecoveryservicesbackup.LongTermRetentionPolicy{ - RetentionPolicyType: to.Ptr(""), - DailySchedule: &armrecoveryservicesbackup.DailyRetentionSchedule{ - RetentionDuration: &armrecoveryservicesbackup.RetentionDuration{ - Count: to.Ptr[int32](5), - DurationType: to.Ptr(armrecoveryservicesbackup.RetentionDurationTypeDays), - }, - RetentionTimes: []*time.Time{ - to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-09-29T08:00:00.000Z"); return t }())}, - }, - MonthlySchedule: &armrecoveryservicesbackup.MonthlyRetentionSchedule{ - RetentionDuration: &armrecoveryservicesbackup.RetentionDuration{ - Count: to.Ptr[int32](60), - DurationType: to.Ptr(armrecoveryservicesbackup.RetentionDurationTypeMonths), - }, - RetentionScheduleFormatType: to.Ptr(armrecoveryservicesbackup.RetentionScheduleFormatWeekly), - RetentionScheduleWeekly: &armrecoveryservicesbackup.WeeklyRetentionFormat{ - DaysOfTheWeek: []*armrecoveryservicesbackup.DayOfWeek{ - to.Ptr(armrecoveryservicesbackup.DayOfWeekSunday)}, - WeeksOfTheMonth: []*armrecoveryservicesbackup.WeekOfMonth{ - to.Ptr(armrecoveryservicesbackup.WeekOfMonthFirst)}, - }, - RetentionTimes: []*time.Time{ - to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-09-29T08:00:00.000Z"); return t }())}, - }, - WeeklySchedule: &armrecoveryservicesbackup.WeeklyRetentionSchedule{ - DaysOfTheWeek: []*armrecoveryservicesbackup.DayOfWeek{ - to.Ptr(armrecoveryservicesbackup.DayOfWeekSunday)}, - RetentionDuration: &armrecoveryservicesbackup.RetentionDuration{ - Count: to.Ptr[int32](12), - DurationType: to.Ptr(armrecoveryservicesbackup.RetentionDurationTypeWeeks), - }, - RetentionTimes: []*time.Time{ - to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-09-29T08:00:00.000Z"); return t }())}, - }, - YearlySchedule: &armrecoveryservicesbackup.YearlyRetentionSchedule{ - MonthsOfYear: []*armrecoveryservicesbackup.MonthOfYear{ - to.Ptr(armrecoveryservicesbackup.MonthOfYearJanuary)}, - RetentionDuration: &armrecoveryservicesbackup.RetentionDuration{ - Count: to.Ptr[int32](10), - DurationType: to.Ptr(armrecoveryservicesbackup.RetentionDurationTypeYears), - }, - RetentionScheduleFormatType: to.Ptr(armrecoveryservicesbackup.RetentionScheduleFormatWeekly), - RetentionScheduleWeekly: &armrecoveryservicesbackup.WeeklyRetentionFormat{ - DaysOfTheWeek: []*armrecoveryservicesbackup.DayOfWeek{ - to.Ptr(armrecoveryservicesbackup.DayOfWeekSunday)}, - WeeksOfTheMonth: []*armrecoveryservicesbackup.WeekOfMonth{ - to.Ptr(armrecoveryservicesbackup.WeekOfMonthFirst)}, - }, - RetentionTimes: []*time.Time{ - to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-09-29T08:00:00.000Z"); return t }())}, - }, - }, - SchedulePolicy: &armrecoveryservicesbackup.SimpleSchedulePolicy{ - SchedulePolicyType: to.Ptr(""), - ScheduleRunFrequency: to.Ptr(armrecoveryservicesbackup.ScheduleRunTypeDaily), - ScheduleRunTimes: []*time.Time{ - to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2021-09-29T08:00:00.000Z"); return t }())}, - }, - TimeZone: to.Ptr(""), - WorkLoadType: to.Ptr(armrecoveryservicesbackup.WorkloadTypeAzureFileShare), - }, - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ProtectionPolicies_Delete.json -func ExampleProtectionPoliciesClient_BeginDelete() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionPoliciesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - poller, err := client.BeginDelete(ctx, - "", - "", - "", - &armrecoveryservicesbackup.ProtectionPoliciesClientBeginDeleteOptions{ResumeToken: ""}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - _, err = poller.PollUntilDone(ctx, 30*time.Second) - if err != nil { - log.Fatalf("failed to pull the result: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionpolicyoperationresults_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionpolicyoperationresults_client_test.go deleted file mode 100644 index 7a5f9b9ffa67..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionpolicyoperationresults_client_test.go +++ /dev/null @@ -1,41 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ProtectionPolicyOperationResults_Get.json -func ExampleProtectionPolicyOperationResultsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionPolicyOperationResultsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionpolicyoperationstatuses_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionpolicyoperationstatuses_client_test.go deleted file mode 100644 index 42f4302a6920..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_protectionpolicyoperationstatuses_client_test.go +++ /dev/null @@ -1,41 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ProtectionPolicyOperationStatuses_Get.json -func ExampleProtectionPolicyOperationStatusesClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewProtectionPolicyOperationStatusesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_recoverypoints_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_recoverypoints_client_test.go deleted file mode 100644 index 51b443ca2173..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_recoverypoints_client_test.go +++ /dev/null @@ -1,73 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/RecoveryPoints_List.json -func ExampleRecoveryPointsClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewRecoveryPointsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - "", - "", - "", - &armrecoveryservicesbackup.RecoveryPointsClientListOptions{Filter: nil}) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/RecoveryPoints_Get.json -func ExampleRecoveryPointsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewRecoveryPointsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_recoverypointsrecommendedformove_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_recoverypointsrecommendedformove_client_test.go deleted file mode 100644 index d45753410b5d..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_recoverypointsrecommendedformove_client_test.go +++ /dev/null @@ -1,54 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/RecoveryPointsRecommendedForMove_List.json -func ExampleRecoveryPointsRecommendedForMoveClient_NewListPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewRecoveryPointsRecommendedForMoveClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewListPager("", - "", - "", - "", - "", - armrecoveryservicesbackup.ListRecoveryPointsRecommendedForMoveRequest{ - ExcludedRPList: []*string{ - to.Ptr("348916168024334"), - to.Ptr("348916168024335")}, - ObjectType: to.Ptr(""), - }, - nil) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_recoveryservicesbackupclient_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_recoveryservicesbackupclient_client_test.go deleted file mode 100644 index 307b791bac65..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_recoveryservicesbackupclient_client_test.go +++ /dev/null @@ -1,135 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "time" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/BackupDataMove/BackupDataMoveOperationStatus_Get.json -func ExampleClient_GetOperationStatus() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.GetOperationStatus(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/BackupDataMove/PrepareDataMove_Post.json -func ExampleClient_BeginBMSPrepareDataMove() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - poller, err := client.BeginBMSPrepareDataMove(ctx, - "", - "", - armrecoveryservicesbackup.PrepareDataMoveRequest{ - DataMoveLevel: to.Ptr(armrecoveryservicesbackup.DataMoveLevelVault), - TargetRegion: to.Ptr(""), - TargetResourceID: to.Ptr(""), - }, - &armrecoveryservicesbackup.ClientBeginBMSPrepareDataMoveOptions{ResumeToken: ""}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - _, err = poller.PollUntilDone(ctx, 30*time.Second) - if err != nil { - log.Fatalf("failed to pull the result: %v", err) - } -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/BackupDataMove/TriggerDataMove_Post.json -func ExampleClient_BeginBMSTriggerDataMove() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - poller, err := client.BeginBMSTriggerDataMove(ctx, - "", - "", - armrecoveryservicesbackup.TriggerDataMoveRequest{ - CorrelationID: to.Ptr(""), - DataMoveLevel: to.Ptr(armrecoveryservicesbackup.DataMoveLevelVault), - SourceRegion: to.Ptr(""), - SourceResourceID: to.Ptr(""), - }, - &armrecoveryservicesbackup.ClientBeginBMSTriggerDataMoveOptions{ResumeToken: ""}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - _, err = poller.PollUntilDone(ctx, 30*time.Second) - if err != nil { - log.Fatalf("failed to pull the result: %v", err) - } -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/TriggerRecoveryPointMove_Post.json -func ExampleClient_BeginMoveRecoveryPoint() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - poller, err := client.BeginMoveRecoveryPoint(ctx, - "", - "", - "", - "", - "", - "", - armrecoveryservicesbackup.MoveRPAcrossTiersRequest{ - ObjectType: to.Ptr(""), - SourceTierType: to.Ptr(armrecoveryservicesbackup.RecoveryPointTierTypeHardenedRP), - TargetTierType: to.Ptr(armrecoveryservicesbackup.RecoveryPointTierTypeArchivedRP), - }, - &armrecoveryservicesbackup.ClientBeginMoveRecoveryPointOptions{ResumeToken: ""}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - _, err = poller.PollUntilDone(ctx, 30*time.Second) - if err != nil { - log.Fatalf("failed to pull the result: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_resourceguardproxies_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_resourceguardproxies_client_test.go deleted file mode 100644 index 310eec924d4f..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_resourceguardproxies_client_test.go +++ /dev/null @@ -1,44 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/ResourceGuardProxyCRUD/ListResourceGuardProxy.json -func ExampleResourceGuardProxiesClient_NewGetPager() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewResourceGuardProxiesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - pager := client.NewGetPager("", - "", - nil) - for pager.More() { - nextResult, err := pager.NextPage(ctx) - if err != nil { - log.Fatalf("failed to advance page: %v", err) - return - } - for _, v := range nextResult.Value { - // TODO: use page item - _ = v - } - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_resourceguardproxy_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_resourceguardproxy_client_test.go deleted file mode 100644 index 70d7fb645b1f..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_resourceguardproxy_client_test.go +++ /dev/null @@ -1,113 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/ResourceGuardProxyCRUD/GetResourceGuardProxy.json -func ExampleResourceGuardProxyClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewResourceGuardProxyClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/ResourceGuardProxyCRUD/PutResourceGuardProxy.json -func ExampleResourceGuardProxyClient_Put() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewResourceGuardProxyClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Put(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/ResourceGuardProxyCRUD/DeleteResourceGuardProxy.json -func ExampleResourceGuardProxyClient_Delete() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewResourceGuardProxyClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - _, err = client.Delete(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } -} - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/ResourceGuardProxyCRUD/UnlockDeleteResourceGuardProxy.json -func ExampleResourceGuardProxyClient_UnlockDelete() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewResourceGuardProxyClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.UnlockDelete(ctx, - "", - "", - "", - armrecoveryservicesbackup.UnlockDeleteRequest{ - ResourceGuardOperationRequests: []*string{ - to.Ptr("/subscriptions/c999d45b-944f-418c-a0d8-c3fcfd1802c8/resourceGroups/vaultguardRGNew/providers/Microsoft.DataProtection/resourceGuards/VaultGuardTestNew/deleteProtectedItemRequests/default")}, - ResourceToBeDeleted: to.Ptr(""), - }, - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_restores_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_restores_client_test.go deleted file mode 100644 index 89a427708515..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_restores_client_test.go +++ /dev/null @@ -1,67 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "time" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/TriggerRestore_RestoreDisks_IaasVMRestoreRequest.json -func ExampleRestoresClient_BeginTrigger() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewRestoresClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - poller, err := client.BeginTrigger(ctx, - "", - "", - "", - "", - "", - "", - armrecoveryservicesbackup.RestoreRequestResource{ - Properties: &armrecoveryservicesbackup.IaasVMRestoreRequest{ - ObjectType: to.Ptr(""), - CreateNewCloudService: to.Ptr(true), - EncryptionDetails: &armrecoveryservicesbackup.EncryptionDetails{ - EncryptionEnabled: to.Ptr(false), - }, - IdentityInfo: &armrecoveryservicesbackup.IdentityInfo{ - IsSystemAssignedIdentity: to.Ptr(false), - ManagedIdentityResourceID: to.Ptr(""), - }, - OriginalStorageAccountOption: to.Ptr(false), - RecoveryPointID: to.Ptr(""), - RecoveryType: to.Ptr(armrecoveryservicesbackup.RecoveryTypeRestoreDisks), - Region: to.Ptr(""), - SourceResourceID: to.Ptr(""), - StorageAccountID: to.Ptr(""), - }, - }, - &armrecoveryservicesbackup.RestoresClientBeginTriggerOptions{ResumeToken: ""}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - _, err = poller.PollUntilDone(ctx, 30*time.Second) - if err != nil { - log.Fatalf("failed to pull the result: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_securitypins_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_securitypins_client_test.go deleted file mode 100644 index d0617c0b5e62..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_securitypins_client_test.go +++ /dev/null @@ -1,39 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/Common/BackupSecurityPin_Get.json -func ExampleSecurityPINsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewSecurityPINsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - &armrecoveryservicesbackup.SecurityPINsClientGetOptions{Parameters: nil}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_validateoperation_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_validateoperation_client_test.go deleted file mode 100644 index 331d2a095a1e..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_validateoperation_client_test.go +++ /dev/null @@ -1,64 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "time" - - "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/TriggerValidateOperation_RestoreDisk.json -func ExampleValidateOperationClient_BeginTrigger() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewValidateOperationClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - poller, err := client.BeginTrigger(ctx, - "", - "", - &armrecoveryservicesbackup.ValidateIaasVMRestoreOperationRequest{ - ObjectType: to.Ptr(""), - RestoreRequest: &armrecoveryservicesbackup.IaasVMRestoreRequest{ - ObjectType: to.Ptr(""), - CreateNewCloudService: to.Ptr(true), - EncryptionDetails: &armrecoveryservicesbackup.EncryptionDetails{ - EncryptionEnabled: to.Ptr(false), - }, - IdentityInfo: &armrecoveryservicesbackup.IdentityInfo{ - IsSystemAssignedIdentity: to.Ptr(false), - ManagedIdentityResourceID: to.Ptr(""), - }, - OriginalStorageAccountOption: to.Ptr(false), - RecoveryPointID: to.Ptr(""), - RecoveryType: to.Ptr(armrecoveryservicesbackup.RecoveryTypeRestoreDisks), - Region: to.Ptr(""), - SourceResourceID: to.Ptr(""), - StorageAccountID: to.Ptr(""), - }, - }, - &armrecoveryservicesbackup.ValidateOperationClientBeginTriggerOptions{ResumeToken: ""}) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - _, err = poller.PollUntilDone(ctx, 30*time.Second) - if err != nil { - log.Fatalf("failed to pull the result: %v", err) - } -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_validateoperationresults_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_validateoperationresults_client_test.go deleted file mode 100644 index 06c86e7e2a22..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_validateoperationresults_client_test.go +++ /dev/null @@ -1,40 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ValidateOperationResults.json -func ExampleValidateOperationResultsClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewValidateOperationResultsClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_validateoperationstatuses_client_test.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_validateoperationstatuses_client_test.go deleted file mode 100644 index 706c87005d32..000000000000 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/ze_generated_example_validateoperationstatuses_client_test.go +++ /dev/null @@ -1,40 +0,0 @@ -//go:build go1.18 -// +build go1.18 - -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. See License.txt in the project root for license information. -// Code generated by Microsoft (R) AutoRest Code Generator. -// Changes may cause incorrect behavior and will be lost if the code is regenerated. - -package armrecoveryservicesbackup_test - -import ( - "context" - "log" - - "github.com/Azure/azure-sdk-for-go/sdk/azidentity" - "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup" -) - -// Generated from example definition: https://github.com/Azure/azure-rest-api-specs/tree/main/specification/recoveryservicesbackup/resource-manager/Microsoft.RecoveryServices/stable/2021-12-01/examples/AzureIaasVm/ValidateOperationStatus.json -func ExampleValidateOperationStatusesClient_Get() { - cred, err := azidentity.NewDefaultAzureCredential(nil) - if err != nil { - log.Fatalf("failed to obtain a credential: %v", err) - } - ctx := context.Background() - client, err := armrecoveryservicesbackup.NewValidateOperationStatusesClient("", cred, nil) - if err != nil { - log.Fatalf("failed to create client: %v", err) - } - res, err := client.Get(ctx, - "", - "", - "", - nil) - if err != nil { - log.Fatalf("failed to finish the request: %v", err) - } - // TODO: use response item - _ = res -} diff --git a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/zz_generated_constants.go b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/zz_generated_constants.go index a26dae5d82b4..4fc2d6b05bf6 100644 --- a/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/zz_generated_constants.go +++ b/sdk/resourcemanager/recoveryservices/armrecoveryservicesbackup/zz_generated_constants.go @@ -10,7 +10,7 @@ package armrecoveryservicesbackup const ( moduleName = "armrecoveryservicesbackup" - moduleVersion = "v0.5.0" + moduleVersion = "v0.5.1" ) // AcquireStorageAccountLock - Whether storage account lock is to be acquired for this container or not.