Exemple #1
0
func TestNoPassword(t *testing.T) {
	aws := test.StubAws(test.DescribeConvoxStackCycle("convox-test"))
	defer aws.Close()
	defer os.Setenv("RACK", os.Getenv("RACK"))

	os.Setenv("RACK", "convox-test")

	assert.HTTPSuccess(t, controllers.HandlerFunc, "GET", "http://convox/system", nil)
}
Exemple #2
0
// HTTPSuccess asserts that a specified handler returns a success status code.
//
//  assert.HTTPSuccess(t, myHandler, "POST", "http://www.google.com", nil)
//
// Returns whether the assertion was successful (true) or not (false).
func HTTPSuccess(t TestingT, handler http.HandlerFunc, method string, url string, values url.Values) {
	if !assert.HTTPSuccess(t, handler, method, url, values) {
		t.FailNow()
	}
}