| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | |
|
| | |
|
| |
| |
| |
| | |
This mostly affects response.headers['cookie'] for test requests. Use response.cookies instead.
|
| | |
|
| | |
|
| |
| |
| |
| | |
to return its headers and body if the status is a 404.
|
| |
| |
| |
| | |
remaining topics
|
| | |
|
| | |
|
| |
| |
| |
| | |
Added description of how to get hash conditions to use the in expression.
|
| | |
|
|\ \ |
|
| | |
| | |
| | |
| | | |
http://rails.lighthouseapp.com/projects/16213/tickets/16-activerecord-finders#ticket-16-22 minus two points.
|
| |\ \ |
|
| | |\|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Conflicts:
activerecord/lib/active_record/connection_adapters/abstract/connection_specification.rb
activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb
|
| | | | |
|
| | | |
| | | |
| | | |
| | | | |
This reverts commit 5745b25c9f71d86458f2d1cda65f800cbe4e6733.
|
| | |\| |
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
validations_test.rb [#674 state:resolved]
Many of the tests in validations_test would add a new validation to
models. However, only Topic was being reset with a fairly aggressive
clearing of all validations. None of the other models being used however
were recieving the same treatment. Now we use repair_validations(Topic)
for the whole test case because most test cases use Topic and then the
block form of repair_validations(<other_models>) inside any tests that use
other models.
Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
state:resolved]"
This reverts commit e8c1915416579a3840573ca2c80822d96cb31823.
Reasons :
- ActionPack tests run very slow
- Gem.searcher hanging for long time when extension is nil
|
| | | | |
|
| | | | |
|
| | | |\ |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
state:resolved]
Signed-off-by: Frederick Cheung <frederick.cheung@gmail.com>
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
No freeing Result objects causes the MySQL driver to free result sets
at undefined times, this can lead to erratic performance in your
application.
Signed-off-by: Frederick Cheung <frederick.cheung@gmail.com>
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | | |
state:resolved]
|
| | | | |
| | | | |
| | | | |
| | | | | |
Signed-off-by: Frederick Cheung <frederick.cheung@gmail.com>
|
| | | | |
| | | | |
| | | | |
| | | | | |
[#1027 state:resolved]
|
| | | | |
| | | | |
| | | | |
| | | | | |
state:resolved]
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | |/ |
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
with the server side stores [#1591 state:resolved]
Signed-off-by: Joshua Peek <josh@joshpeek.com>
|
| | | |
| | | |
| | | |
| | | | |
Signed-off-by: Joshua Peek <josh@joshpeek.com>
|
| | | |
| | | |
| | | |
| | | | |
to recognize optimize [#1406 state:resolved]
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Instead of calling super to pass the request on, return a 404.
The modified app looks like this:
# app/metal/poller.rb
class Poller
def self.call(env)
if env["PATH_INFO"] =~ /^\/poller/
[200, {"Content-Type" => "text/html"}, "Hello, World!"]
else
[404, {"Content-Type" => "text/html"}, "Not Found"]
end
end
end
But you aren't locked in to just Rails:
# app/metal/api.rb
require 'sinatra'
Sinatra::Application.default_options.merge!(:run => false, :env => :production)
Api = Sinatra.application unless defined? Api
get '/interesting/new/ideas' do
'Hello Sinatra!'
end
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
integration testing. A test for the following Metal:
class Poller < Rails::Rack::Metal
def call(env)
if env["PATH_INFO"] =~ /^\/poller/
[200, {"Content-Type" => "text/plain"}, "Hello World!"]
else
super
end
end
end
might be tested like so:
class PollerTest < ActionController::IntegrationTest
test "poller returns hello world" do
get "/poller"
assert_response 200
assert_response :success
assert_response :ok
assert_equal "Hello World!", response.body
end
end
[#1588 state:committed]
Signed-off-by: David Heinemeier Hansson <david@loudthinking.com>
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
# app/metal/poller.rb
class Poller < Rails::Rack::Metal
def call(env)
if env["PATH_INFO"] =~ /^\/poller/
[200, {"Content-Type" => "application/json"}, Message.recent.to_json]
else
super
end
end
end
* There is a generator to help you get started
`script/generate metal poller`
* Also, metal bits can be ran standalone with rackup
`rackup app/metal/poller.rb`
|