diff options
Diffstat (limited to 'test/rails/app-1.2.3/app/controllers')
-rw-r--r-- | test/rails/app-1.2.3/app/controllers/application.rb | 6 | ||||
-rw-r--r-- | test/rails/app-1.2.3/app/controllers/foo_controller.rb | 36 |
2 files changed, 0 insertions, 42 deletions
diff --git a/test/rails/app-1.2.3/app/controllers/application.rb b/test/rails/app-1.2.3/app/controllers/application.rb deleted file mode 100644 index e72474f..0000000 --- a/test/rails/app-1.2.3/app/controllers/application.rb +++ /dev/null @@ -1,6 +0,0 @@ -# -*- encoding: binary -*- - -class ApplicationController < ActionController::Base - # Pick a unique cookie name to distinguish our session data from others' - session :session_key => "_unicorn_rails_test.#{rand}" -end diff --git a/test/rails/app-1.2.3/app/controllers/foo_controller.rb b/test/rails/app-1.2.3/app/controllers/foo_controller.rb deleted file mode 100644 index 52b7947..0000000 --- a/test/rails/app-1.2.3/app/controllers/foo_controller.rb +++ /dev/null @@ -1,36 +0,0 @@ -# -*- encoding: binary -*- - -require 'digest/sha1' -class FooController < ApplicationController - def index - render :text => "FOO\n" - end - - def xcookie - cookies["foo"] = "cookie #$$" - render :text => "" - end - - def xnotice - flash[:notice] = "session #$$" - render :text => "" - end - - def xpost - if request.post? - digest = Digest::SHA1.new - out = "params: #{params.inspect}\n" - if file = params[:file] - loop do - buf = file.read(4096) or break - digest.update(buf) - end - out << "sha1: #{digest.to_s}\n" - end - headers['content-type'] = 'text/plain' - render :text => out - else - render :status => 403, :text => "need post\n" - end - end -end |