skill-assessment-app/test/controllers/admin_controller_test.rb
2016-08-22 16:26:21 -05:00

16 lines
393 B
Ruby

require 'test_helper'
class AdminControllerTest < ActionDispatch::IntegrationTest
test "dashboard should require auth" do
get admin_url
assert_redirected_to admin_login_url
end
test "should get dashboard" do
post admin_auth_url, params: { auth:
{ email: 'alan.admin@mailinator.com', password: 'password' } }
get admin_url
assert_response :success
end
end