Skip to content

Commit

Permalink
Fix integration test
Browse files Browse the repository at this point in the history
  • Loading branch information
Cheng Pan committed Dec 21, 2018
1 parent 8f522f1 commit b56ea8e
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pkg/cloud/cloud.go
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@ func (c *cloud) waitForVolume(ctx context.Context, volumeID string) error {
case "available":
return true, nil
case "creating":
return false, fmt.Errorf("volume %s is still being created", volumeID)
return false, nil
default:
return true, fmt.Errorf("unexpected state for volume %s: %q", volumeID, *vol.State)
}
Expand Down
4 changes: 3 additions & 1 deletion tests/integration/integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,9 @@ var _ = Describe("EBS CSI Driver", func() {
}()

// Attach, stage, publish, unpublish, unstage, detach
nodeID := ebs.GetMetadata().GetInstanceID()
metadata, err := newMetadata()
Expect(err).To(BeNil())
nodeID := metadata.GetInstanceID()
testAttachWriteReadDetach(volume.VolumeId, req.GetName(), nodeID, false)

})
Expand Down
1 change: 0 additions & 1 deletion tests/integration/setup_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ var (
drv *driver.Driver
csiClient *CSIClient
ec2Client *ec2.EC2
ebs cloud.Cloud
)

func TestIntegration(t *testing.T) {
Expand Down

0 comments on commit b56ea8e

Please sign in to comment.