Browse code

It should be volume not binds for first arg in callDecodeContainerConfig()

Signed-off-by: lixiaobing10051267 <li.xiaobing1@zte.com.cn>

lixiaobing10051267 authored on 2016/08/02 23:20:08
Showing 1 changed files
... ...
@@ -186,7 +186,7 @@ func TestDecodeContainerConfigVolumes(t *testing.T) {
186 186
 		t.Fatalf("binds %v should have failed", bindsOrVols)
187 187
 	}
188 188
 	if _, _, err := callDecodeContainerConfig(bindsOrVols, nil); err == nil {
189
-		t.Fatalf("binds %v should have failed", bindsOrVols)
189
+		t.Fatalf("volume %v should have failed", bindsOrVols)
190 190
 	}
191 191
 
192 192
 	//	// No destination path or mode
... ...
@@ -195,7 +195,7 @@ func TestDecodeContainerConfigVolumes(t *testing.T) {
195 195
 		t.Fatalf("binds %v should have failed", bindsOrVols)
196 196
 	}
197 197
 	if _, _, err := callDecodeContainerConfig(bindsOrVols, nil); err == nil {
198
-		t.Fatalf("binds %v should have failed", bindsOrVols)
198
+		t.Fatalf("volume %v should have failed", bindsOrVols)
199 199
 	}
200 200
 
201 201
 	// A whole lot of nothing
... ...
@@ -204,7 +204,7 @@ func TestDecodeContainerConfigVolumes(t *testing.T) {
204 204
 		t.Fatalf("binds %v should have failed", bindsOrVols)
205 205
 	}
206 206
 	if _, _, err := callDecodeContainerConfig(bindsOrVols, nil); err == nil {
207
-		t.Fatalf("binds %v should have failed", bindsOrVols)
207
+		t.Fatalf("volume %v should have failed", bindsOrVols)
208 208
 	}
209 209
 
210 210
 	// A whole lot of nothing with no mode
... ...
@@ -213,7 +213,7 @@ func TestDecodeContainerConfigVolumes(t *testing.T) {
213 213
 		t.Fatalf("binds %v should have failed", bindsOrVols)
214 214
 	}
215 215
 	if _, _, err := callDecodeContainerConfig(bindsOrVols, nil); err == nil {
216
-		t.Fatalf("binds %v should have failed", bindsOrVols)
216
+		t.Fatalf("volume %v should have failed", bindsOrVols)
217 217
 	}
218 218
 
219 219
 	// Too much including an invalid mode
... ...
@@ -223,7 +223,7 @@ func TestDecodeContainerConfigVolumes(t *testing.T) {
223 223
 		t.Fatalf("binds %v should have failed", bindsOrVols)
224 224
 	}
225 225
 	if _, _, err := callDecodeContainerConfig(bindsOrVols, nil); err == nil {
226
-		t.Fatalf("binds %v should have failed", bindsOrVols)
226
+		t.Fatalf("volume %v should have failed", bindsOrVols)
227 227
 	}
228 228
 
229 229
 	// Windows specific error tests
... ...
@@ -234,7 +234,7 @@ func TestDecodeContainerConfigVolumes(t *testing.T) {
234 234
 			t.Fatalf("binds %v should have failed", bindsOrVols)
235 235
 		}
236 236
 		if _, _, err := callDecodeContainerConfig(bindsOrVols, nil); err == nil {
237
-			t.Fatalf("binds %v should have failed", bindsOrVols)
237
+			t.Fatalf("volume %v should have failed", bindsOrVols)
238 238
 		}
239 239
 
240 240
 		// Root to C-Drive
... ...
@@ -243,7 +243,7 @@ func TestDecodeContainerConfigVolumes(t *testing.T) {
243 243
 			t.Fatalf("binds %v should have failed", bindsOrVols)
244 244
 		}
245 245
 		if _, _, err := callDecodeContainerConfig(bindsOrVols, nil); err == nil {
246
-			t.Fatalf("binds %v should have failed", bindsOrVols)
246
+			t.Fatalf("volume %v should have failed", bindsOrVols)
247 247
 		}
248 248
 
249 249
 		// Container path that does not include a drive letter
... ...
@@ -252,7 +252,7 @@ func TestDecodeContainerConfigVolumes(t *testing.T) {
252 252
 			t.Fatalf("binds %v should have failed", bindsOrVols)
253 253
 		}
254 254
 		if _, _, err := callDecodeContainerConfig(bindsOrVols, nil); err == nil {
255
-			t.Fatalf("binds %v should have failed", bindsOrVols)
255
+			t.Fatalf("volume %v should have failed", bindsOrVols)
256 256
 		}
257 257
 	}
258 258
 
... ...
@@ -264,7 +264,7 @@ func TestDecodeContainerConfigVolumes(t *testing.T) {
264 264
 			t.Fatalf("binds %v should have failed", bindsOrVols)
265 265
 		}
266 266
 		if _, _, err := callDecodeContainerConfig(bindsOrVols, nil); err == nil {
267
-			t.Fatalf("binds %v should have failed", bindsOrVols)
267
+			t.Fatalf("volume %v should have failed", bindsOrVols)
268 268
 		}
269 269
 
270 270
 		// A single volume that looks like a bind mount passed in Volumes.