diff --git a/e2etest/zt_newe2e_basic_functionality_test.go b/e2etest/zt_newe2e_basic_functionality_test.go index e3cc384db..bbd46818f 100644 --- a/e2etest/zt_newe2e_basic_functionality_test.go +++ b/e2etest/zt_newe2e_basic_functionality_test.go @@ -1,11 +1,10 @@ package e2etest import ( - "strconv" - "time" - blobsas "github.com/Azure/azure-sdk-for-go/sdk/storage/azblob/sas" "github.com/Azure/azure-storage-azcopy/v10/common" + "strconv" + "time" ) func init() { @@ -485,58 +484,3 @@ func (s *BasicFunctionalitySuite) Scenario_TagsPermission(svm *ScenarioVariation ValidateMessageOutput(svm, stdOut, "Authorization failed during an attempt to set tags, please ensure you have the appropriate Tags permission") } - -func (s *BasicFunctionalitySuite) Scenario_SingleFile_PanicCheck(svm *ScenarioVariationManager) { - azCopyVerb := ResolveVariation(svm, []AzCopyVerb{AzCopyVerbCopy, AzCopyVerbSync}) // Calculate verb early to create the destination object early - // Scale up from service to object - dstObj := CreateResource[ContainerResourceManager](svm, GetRootResource(svm, ResolveVariation(svm, []common.Location{common.ELocation.Local(), common.ELocation.Blob(), common.ELocation.File(), common.ELocation.BlobFS()})), ResourceDefinitionContainer{}).GetObject(svm, "test", common.EEntityType.File()) - // The object must exist already if we're syncing. - if azCopyVerb == AzCopyVerbSync { - dstObj.Create(svm, NewZeroObjectContentContainer(0), ObjectProperties{}) - - if !svm.Dryrun() { - // Make sure the LMT is in the past - time.Sleep(time.Second * 10) - } - } - - body := NewRandomObjectContentContainer(SizeFromString("10K")) - // Scale up from service to object - srcObj := CreateResource[ObjectResourceManager](svm, GetRootResource(svm, ResolveVariation(svm, []common.Location{common.ELocation.Local(), common.ELocation.Blob(), common.ELocation.File(), common.ELocation.BlobFS()})), ResourceDefinitionObject{ - ObjectName: pointerTo("test"), - Body: body, - }) - - // no local->local - if srcObj.Location().IsLocal() && dstObj.Location().IsLocal() { - svm.InvalidateScenario() - return - } - - sasOpts := GenericAccountSignatureValues{} - sasOpts.Permissions = (&blobsas.ContainerPermissions{ - Read: true, Add: false, Create: false, Write: false, Delete: false, List: false, - }).String() - - stdOut, _ := RunAzCopy( - svm, - AzCopyCommand{ - Verb: azCopyVerb, - Targets: []ResourceManager{ - TryApplySpecificAuthType(srcObj, EExplicitCredentialType.SASToken(), svm, CreateAzCopyTargetOptions{ - SASTokenOptions: sasOpts, - }), - TryApplySpecificAuthType(dstObj, EExplicitCredentialType.SASToken(), svm, CreateAzCopyTargetOptions{ - SASTokenOptions: sasOpts, - }), - }, - Flags: CopyFlags{ - CopySyncCommonFlags: CopySyncCommonFlags{ - Recursive: pointerTo(true), - }, - }, - ShouldFail: true, - }) - ValidateMessageOutput(svm, stdOut, "panic") - -}