Skip to content

Commit

Permalink
Merge pull request #2559 from andyzhangx/snapshot-xfs-test
Browse files Browse the repository at this point in the history
test: add snapshot restore test on xfs file system
  • Loading branch information
andyzhangx authored Oct 19, 2024
2 parents 5d65e27 + 858aa11 commit e813de5
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions test/e2e/dynamic_provisioning_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -763,17 +763,22 @@ func (t *dynamicProvisioningTestSuite) defineTests(isMultiZone bool) {
test.Run(ctx, cs, snapshotrcs, ns)
})

ginkgo.It("should create a pod, write to its pv, take a volume snapshot, overwrite data in original pv, create another pod from the snapshot, and read unaltered original data from original pv[disk.csi.azure.com]", func(ctx ginkgo.SpecContext) {
ginkgo.It("should create a pod, write to its pv, take a volume snapshot with xfs fs, overwrite data in original pv, create another pod from the snapshot, and read unaltered original data from original pv[disk.csi.azure.com]", func(ctx ginkgo.SpecContext) {
skipIfUsingInTreeVolumePlugin()
skipIfTestingInWindowsCluster()

fsType := "xfs"
if isWindowsCluster {
fsType = "ntfs"
}

pod := testsuites.PodDetails{
IsWindows: isWindowsCluster,
WinServerVer: winServerVer,
Cmd: convertToPowershellorCmdCommandIfNecessary("echo 'hello world' > /mnt/test-1/data"),
Volumes: t.normalizeVolumes([]testsuites.VolumeDetails{
{
FSType: getFSType(isWindowsCluster),
FSType: fsType,
ClaimSize: "10Gi",
VolumeMount: testsuites.VolumeMountDetails{
NameGenerate: "test-volume-",
Expand Down

0 comments on commit e813de5

Please sign in to comment.