From cb4a8cb5c72da87bc3eabf9fbbd935914c0ce5fe Mon Sep 17 00:00:00 2001 From: ashmrtn <3891298+ashmrtn@users.noreply.github.com> Date: Wed, 15 Nov 2023 17:06:59 -0800 Subject: [PATCH] Use microsecond granularity for exchange tests (#4695) Switch the folder name granularity to microseconds instead of seconds to avoid collisions with other concurrent CI test runs. --- #### Does this PR need a docs update or release note? - [ ] :white_check_mark: Yes, it's included - [ ] :clock1: Yes, but in a later PR - [x] :no_entry: No #### Type of change - [ ] :sunflower: Feature - [ ] :bug: Bugfix - [ ] :world_map: Documentation - [ ] :robot: Supportability/Tests - [x] :computer: CI/Deployment - [ ] :broom: Tech Debt/Cleanup #### Test Plan - [x] :muscle: Manual - [ ] :zap: Unit test - [ ] :green_heart: E2E --- src/internal/m365/controller_test.go | 6 +++--- src/internal/m365/onedrive_test.go | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/internal/m365/controller_test.go b/src/internal/m365/controller_test.go index f6074067d..6fe930c1a 100644 --- a/src/internal/m365/controller_test.go +++ b/src/internal/m365/controller_test.go @@ -1073,7 +1073,7 @@ func (suite *ControllerIntegrationSuite) TestRestoreAndBackup_core() { suite.ctrl.tenant, []string{suite.user}, control.DefaultOptions(), - control.DefaultRestoreConfig(dttm.HumanReadableDriveItem)) + control.DefaultRestoreConfig(dttm.SafeForTesting)) }) } } @@ -1242,7 +1242,7 @@ func (suite *ControllerIntegrationSuite) TestMultiFolderBackupDifferentNames() { t.Log("Backup enumeration complete") - restoreCfg := control.DefaultRestoreConfig(dttm.HumanReadableDriveItem) + restoreCfg := control.DefaultRestoreConfig(dttm.SafeForTesting) restoreCfg.IncludePermissions = true ci := stub.ConfigInfo{ @@ -1285,7 +1285,7 @@ func (suite *ControllerIntegrationSuite) TestRestoreAndBackup_largeMailAttachmen }, } - restoreCfg := control.DefaultRestoreConfig(dttm.HumanReadableDriveItem) + restoreCfg := control.DefaultRestoreConfig(dttm.SafeForTesting) restoreCfg.IncludePermissions = true runRestoreBackupTest( diff --git a/src/internal/m365/onedrive_test.go b/src/internal/m365/onedrive_test.go index fb591e1c0..48de85558 100644 --- a/src/internal/m365/onedrive_test.go +++ b/src/internal/m365/onedrive_test.go @@ -1355,7 +1355,7 @@ func testRestoreFolderNamedFolderRegression( collectionsLatest: expected, } - restoreCfg := control.DefaultRestoreConfig(dttm.HumanReadableDriveItem) + restoreCfg := control.DefaultRestoreConfig(dttm.SafeForTesting) restoreCfg.IncludePermissions = true runRestoreTestWithVersion(