Mislav Marohnić
2cd8d3b4c5
form helpers: twakes based on feedback; more content; set outline for remaining topics
2008-12-25 00:23:51 +01:00
Ryan Bigg
ee69bac14e
Xavier Noria suggestions added! Guides #16 , parts 27-29.
2008-12-23 21:28:10 +10:30
Ryan Bigg
d4a5c9c4ef
Added section on having.
2008-12-22 00:27:37 +10:30
Ryan Bigg
e691d486a9
Added section about using expressions as values for the lock option.
...
Added description of how to get hash conditions to use the in expression.
2008-12-22 00:15:59 +10:30
Colin Curtin
10e601bd91
Command Line Guide: Added short console/dbconsole/plugin/runner/destroy/about
2008-12-20 20:34:58 -08:00
Colin Curtin
0e121f9ed9
Merge branch 'master' of git@github.com:lifo/docrails
2008-12-20 20:21:20 -08:00
Ryan Bigg
a0d091a416
Fixed http://rails.lighthouseapp.com/projects/16213/tickets/16-activerecord-finders#ticket-16-22 minus two points.
2008-12-21 13:55:14 +10:30
Ryan Bigg
4fc9f69e54
Merge branch 'master' of git@github.com:lifo/docrails
2008-12-21 13:30:51 +10:30
Ryan Bigg
199f4c54ea
Added more to the hashn conditions section.
2008-12-21 13:28:11 +10:30
Pratik Naik
19939fd4c0
Merge commit 'mainstream/master'
...
Conflicts:
activerecord/lib/active_record/connection_adapters/abstract/connection_specification.rb
activerecord/lib/active_record/connection_adapters/abstract/schema_definitions.rb
2008-12-19 14:29:14 +00:00
Pratik Naik
c3f53f412c
Merge docrails
2008-12-19 14:27:43 +00:00
Pratik Naik
2d78ee0de6
Revert "Fix example using wrong method name"
...
This reverts commit 5745b25c9f .
2008-12-19 14:25:58 +00:00
Pratik Naik
6c375d9505
Merge commit 'mainstream/master'
2008-12-19 14:10:42 +00:00
Pratik Naik
89b7581404
Add repair_helper.rb file I forgot in previous commit 8a92cd
2008-12-19 13:52:21 +00:00
Murray Steele
8a92cdc863
Add a repair_helper to repair changes to the validations inside 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 >
2008-12-19 13:37:50 +00:00
Pratik Naik
c044c079ab
Revert "Auto-load template handlers based on unmatched extensions [ #1540 state:resolved]"
...
This reverts commit e8c1915416 .
Reasons :
- ActionPack tests run very slow
- Gem.searcher hanging for long time when extension is nil
2008-12-19 13:05:45 +00:00
Ryan Bigg
46702e6a6d
Merge branch 'master' of git@github.com:lifo/docrails
2008-12-19 22:11:29 +10:30
Ryan Bigg
0021f5e655
Better documentation for options_from_collection_for_select.
2008-12-19 22:10:46 +10:30
Jeremy Kemper
6ce4b43035
Cheaper metal cascade
2008-12-18 16:55:03 -08:00
Jeremy Kemper
03f6ecc6c6
Use LogTailer
2008-12-18 16:53:53 -08:00
Jeremy Kemper
248391a7e1
Merge branch 'master' of git@github.com:rails/rails
2008-12-18 14:49:02 -08:00
Jeremy Kemper
86abd6887d
Ensure rack.multithread is set back to original value. Accept external lock.
2008-12-18 14:48:53 -08:00
Jeremy Kemper
788ab8458a
No need to dup immutable options
2008-12-18 14:42:58 -08:00
Jeremy Kemper
c81cd321d1
Be sure to call super
2008-12-18 14:42:39 -08:00
Jeremy Kemper
a10e473b81
Rename Rails::Rack::Logger -> LogTailer. Speed up log mtime checks.
2008-12-18 14:42:06 -08:00
Jeremy Kemper
6703f909c7
Cheaper log tail time comparison
2008-12-18 14:17:43 -08:00
Matt Jones
a9422cc1db
Fix preloading of has_one :through associations on belongs_to [ #1507 state:resolved]
...
Signed-off-by: Frederick Cheung <frederick.cheung@gmail.com >
2008-12-18 19:19:36 +00:00
Manfred Stienstra
8326b95169
Free MySQL::Result objects after a call to execute [ #1416 state:resolved]
...
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 >
2008-12-18 19:19:36 +00:00
Frederick Cheung
9c7fe7c672
Don't include table_name twice
2008-12-18 19:19:36 +00:00
Frederick Cheung
c9ab7098be
Ensure :include checks joins when determining if it can preload [ #528 state:resolved]
2008-12-18 19:19:36 +00:00
Emilio Tagua
9cf6b1b15e
Add missing model files so tests can run isolated [ #1506 state:resolved]
...
Signed-off-by: Frederick Cheung <frederick.cheung@gmail.com >
2008-12-18 19:19:36 +00:00
Frederick Cheung
707d0dd3e1
Fix preloading of belongs_to with null foreign key generating useless query [ #1027 state:resolved]
2008-12-18 19:19:35 +00:00
Frederick Cheung
428e77bf0f
Make exceptions raise from find_by_foo! have a more helpful message [ #1567 state:resolved]
2008-12-18 19:19:35 +00:00
Joshua Peek
a9fde9a2ab
Cleanup dispatch path
2008-12-18 13:14:09 -06:00
Joshua Peek
3b35366d5d
Use more generic test env flag
2008-12-18 12:57:37 -06:00
Joshua Peek
2e22c7fda0
Conditionally inject session middleware instead of using session management
2008-12-18 12:56:18 -06:00
Joshua Peek
2eb2ec9e63
Move gaint lock into middleware
2008-12-18 12:00:54 -06:00
Lourens Naude
3ff6b00ee3
Persistent session identifier support for CookieSessionStore and API compat. with the server side stores [ #1591 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2008-12-18 11:33:53 -06:00
Brady Bouchard
33f76bb25a
Ensure error file is sent with a 'text/html' content type [ #1478 state:resolved]
...
Signed-off-by: Joshua Peek <josh@joshpeek.com >
2008-12-17 10:23:59 -06:00
Joshua Peek
f23c2796ee
When checking for the wrong routing method, ensure the environment is passed to recognize optimize [ #1406 state:resolved]
2008-12-17 10:20:19 -06:00
Joshua Peek
175cb7a963
Fix metal tests
2008-12-17 10:10:24 -06:00
Joshua Peek
61a41154f7
Make generated Metal bits a pure rack endpoint application (not middleware)
...
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
2008-12-17 09:53:56 -06:00
Jesse Newland
97a178bfa4
Decorate responses from Rack Middleware and Rails Metal for the purposes of 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 >
2008-12-17 15:59:47 +01:00
Mike Gunderloy
17f3ab3b83
Fix bad link in Getting Started, rebuild HTML
2008-12-17 07:11:59 -06:00
Ryan Bigg
9b2dd332f1
Correct one instance of table syntax.
2008-12-17 22:21:05 +10:30
Colin Curtin
b0187434bd
Started working with the scaffold instead of model generator to teach models
2008-12-16 23:06:11 -08:00
Joshua Peek
1bcfce0130
Remove set_cookie hack from rack response since we dont use cgi sessions anymore
2008-12-16 20:21:27 -06:00
Joshua Peek
246b582ddf
Remove CGI::Session memory leak patch
2008-12-16 19:56:09 -06:00
Ryan Bigg
fd117c52fa
Fixed up syntax errors.
2008-12-17 09:33:10 +10:30
Joshua Peek
ec1bd98705
Session Fixation tests have been rolled into the session cookie tests
2008-12-16 16:28:39 -06:00