summaryrefslogtreecommitdiff
path: root/certs/test/functional/certs_controller_test.rb
diff options
context:
space:
mode:
authorAzul <azul@leap.se>2012-11-19 14:47:19 +0100
committerAzul <azul@leap.se>2012-11-19 14:47:19 +0100
commitc8cf2f5911f09d6898cff7d6a79f139272b065e7 (patch)
tree9602e8b1dfd7e63a6d77121cf7e7d576c516f031 /certs/test/functional/certs_controller_test.rb
parent5a5e73f2fefa8e1a06f18063a6d644a6d1c2a869 (diff)
parent9810d5b66ca7f81df402e9b05957466a947bdf9b (diff)
Merge branch 'feature-require_login_for_cert_download' into develop
Diffstat (limited to 'certs/test/functional/certs_controller_test.rb')
-rw-r--r--certs/test/functional/certs_controller_test.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/certs/test/functional/certs_controller_test.rb b/certs/test/functional/certs_controller_test.rb
index 295515b..9bba8c0 100644
--- a/certs/test/functional/certs_controller_test.rb
+++ b/certs/test/functional/certs_controller_test.rb
@@ -4,7 +4,14 @@ class CertsControllerTest < ActionController::TestCase
setup do
end
+ test "should require login" do
+ get :show
+ assert_response :redirect
+ assert_redirected_to login_url
+ end
+
test "should send cert" do
+ login
cert = stub :zipped => "adsf", :zipname => "cert_stub.zip"
Cert.expects(:pick_from_pool).returns(cert)
get :show