From 2271f2747645cf99306944aaf3eb4a11fa4d6657 Mon Sep 17 00:00:00 2001 From: Anton Kuchin Date: Mon, 23 Sep 2024 06:40:17 +0200 Subject: [PATCH] staged csi: add comment to remember enable check later According to spec target directory must be removed after NodeUnstage but now mounter mock doesn't delete it during mount point cleanup. If directory deletion is enabled then other test breaks because it relies on previous tests leaving temoprary directories. This will be fixed separately form this PR. Signed-off-by: Anton Kuchin --- .../tools/csi_driver/internal/driver/node_test.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/cloud/blockstore/tools/csi_driver/internal/driver/node_test.go b/cloud/blockstore/tools/csi_driver/internal/driver/node_test.go index 1517abb2ba6..a27d907192d 100644 --- a/cloud/blockstore/tools/csi_driver/internal/driver/node_test.go +++ b/cloud/blockstore/tools/csi_driver/internal/driver/node_test.go @@ -335,6 +335,13 @@ func doTestStagedPublishUnpublishVolumeForKubevirt(t *testing.T, backend string, }) require.NoError(t, err) + // TODO: enable check that target directory is deleted + // mock mounter should remove targetPath but if it does then TestGetVolumeStatCapabilitiesWithoutVmMode + // fails because it relies on other tests leaving target directory (it fails if launched alone) + // + //_, err = os.Stat(targetPath) + //assert.True(t, os.IsNotExist(err)) + if backend == "nbs" { nbsClient.On("StopEndpoint", ctx, &nbs.TStopEndpointRequest{ UnixSocketPath: nbsSocketPath,