mirror of
				https://github.com/optim-enterprises-bv/kubernetes.git
				synced 2025-11-04 04:08:16 +00:00 
			
		
		
		
	Merge pull request #54843 from linyouchong/linyouchong-20171031
Automatic merge from submit-queue (batch tested with PRs 54843, 55810). 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>. fix testSupport in downwardapi_test add some code to test plugin.CanSupport function /sig storage
This commit is contained in:
		@@ -63,6 +63,12 @@ func TestCanSupport(t *testing.T) {
 | 
			
		||||
	if plugin.GetPluginName() != downwardAPIPluginName {
 | 
			
		||||
		t.Errorf("Wrong name: %s", plugin.GetPluginName())
 | 
			
		||||
	}
 | 
			
		||||
	if !plugin.CanSupport(&volume.Spec{Volume: &v1.Volume{VolumeSource: v1.VolumeSource{DownwardAPI: &v1.DownwardAPIVolumeSource{}}}}) {
 | 
			
		||||
		t.Errorf("Expected true")
 | 
			
		||||
	}
 | 
			
		||||
	if plugin.CanSupport(&volume.Spec{Volume: &v1.Volume{VolumeSource: v1.VolumeSource{}}}) {
 | 
			
		||||
		t.Errorf("Expected false")
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
func TestDownwardAPI(t *testing.T) {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user