mirror of https://github.com/kubernetes/kops.git
				
				
				
			Add a glog dependency to the test
This commit is contained in:
		
							parent
							
								
									8d31671252
								
							
						
					
					
						commit
						288af117fe
					
				| 
						 | 
				
			
			@ -17,6 +17,7 @@ limitations under the License.
 | 
			
		|||
package featureflag
 | 
			
		||||
 | 
			
		||||
import (
 | 
			
		||||
	"github.com/golang/glog"
 | 
			
		||||
	"os"
 | 
			
		||||
	"testing"
 | 
			
		||||
)
 | 
			
		||||
| 
						 | 
				
			
			@ -27,6 +28,9 @@ func TestFlagToFalse(t *testing.T) {
 | 
			
		|||
		t.Fatalf("Flag did not default true")
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	// Really just to force a dependency on glog, so that we can pass -v and -logtostderr to go test
 | 
			
		||||
	glog.Infof("Created flag Unittest1")
 | 
			
		||||
 | 
			
		||||
	ParseFlags("-UnitTest1")
 | 
			
		||||
	if f.Enabled() {
 | 
			
		||||
		t.Fatalf("Flag did not default turn off")
 | 
			
		||||
| 
						 | 
				
			
			@ -38,7 +42,7 @@ func TestFlagToFalse(t *testing.T) {
 | 
			
		|||
	}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
func Setenv(t *testing.T) {
 | 
			
		||||
func TestSetenv(t *testing.T) {
 | 
			
		||||
	f := New("UnitTest2", Bool(true))
 | 
			
		||||
	if !f.Enabled() {
 | 
			
		||||
		t.Fatalf("Flag did not default true")
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue