Unverified Commit 8684e581 authored by Kubernetes Submit Queue's avatar Kubernetes Submit Queue Committed by GitHub

Merge pull request #54970 from jianglingxia/jlx-storageos

Automatic merge from submit-queue (batch tested with PRs 60457, 60331, 54970, 58731, 60562). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Remove val and ok in Storageos **What this PR does / why we need it**: in for loop has define the two para **Which issue(s) this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close the issue(s) when PR gets merged)*: Fixes # **Special notes for your reviewer**: **Release note**: ```release-note NONE ```
parents c0db49c2 2522b046
......@@ -184,9 +184,9 @@ func TestCreateVolume(t *testing.T) {
if len(vol.Labels) == 0 {
t.Error("CreateVolume() Labels are empty")
} else {
var val string
var ok bool
for k, v := range labels {
var val string
var ok bool
if val, ok = vol.Labels[k]; !ok {
t.Errorf("CreateVolume() Label %s not set", k)
}
......@@ -194,8 +194,6 @@ func TestCreateVolume(t *testing.T) {
t.Errorf("CreateVolume() returned unexpected Label value %s", val)
}
}
var val string
var ok bool
if val, ok = vol.Labels["labelfromapi"]; !ok {
t.Error("CreateVolume() Label from api not set")
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment