We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
FAILED_PRECONDITION
NodePublishVolume
1 parent 08cdd2e commit ae0d21aCopy full SHA for ae0d21a
pkg/sanity/node.go
@@ -392,6 +392,21 @@ var _ = DescribeSanity("Node Service", func(sc *TestContext) {
392
Expect(serverError.Code()).To(Equal(codes.InvalidArgument))
393
})
394
395
+ It("should fail when no staging target path is provided", func() {
396
+ if !nodeStageSupported {
397
+ Skip("STAGE_UNSTAGE_VOLUME not supported")
398
+ }
399
+
400
+ req.StagingTargetPath = ""
401
402
+ _, err := c.NodePublishVolume(context.Background(), req)
403
+ Expect(err).To(HaveOccurred())
404
405
+ serverError, ok := status.FromError(err)
406
+ Expect(ok).To(BeTrue())
407
+ Expect(serverError.Code()).To(Equal(codes.FailedPrecondition))
408
+ })
409
410
It("should fail when no volume capability is provided", func() {
411
req.VolumeCapability = nil
412
0 commit comments