Commit Graph

38237 Commits

Author SHA1 Message Date
Yves Senn
ce13dc28e4 Merge pull request #10942 from yangchenyun/mine
correct documentation about active_record.default_timezone
2013-06-16 22:52:48 -07:00
dtaniwaki
c91e1cca43 Added test for link_to_unless to make sure the result consistency. 2013-06-16 22:28:49 -04:00
dtaniwaki
a84c40e19a Escape the string even when the condition of link_to_unless is not satisfied. 2013-06-16 22:28:40 -04:00
Rafael Mendonça França
2d2f35ddf2 Add CHANGELOG entry for #10969
[ci skip]
2013-06-16 21:37:46 -03:00
Rafael Mendonça França
0117f28b98 Merge pull request #10969 from davidcelis/case-insensitive-asset-path
Use a case insensitive URI Regexp for #asset_path
2013-06-16 17:27:53 -07:00
David Celis
8fc3427646 Use a case insensitive URI Regexp for #asset_path
Context: https://gist.github.com/radar/5793814

The `URI_REGEXP` that various AssetUrl helpers use is currently case
sensitive when checking for a URI scheme. This means if you try to pass
a URL like `HTTP://www.example.com/path/to/image.jpg`, you end up with
a bogus asset path: `/assets/HTTP://www.example.com/path/to/image.jpg`.

URLs are case insensitive, so this regexp should be as well.

Signed-off-by: David Celis <me@davidcel.is>
2013-06-16 16:57:49 -07:00
wangjohn
f0e6666187 Removing a repetitive comment and refactoring the Application class in
Railties.

The comment on the +env_config+ method is repetitive, likely to get
outdated, and provides no useful information which cannot be gleamed
from the code. I'm therefore removing it. I'm also refactoring the check
for the presence of a secret_token in the configuration.
2013-06-16 15:57:47 -07:00
wangjohn
685309cf59 Creating a class to build the default middleware stack.
A lot of logic for building the default middleware stack is currently
kept in Application class, but this can be encapsulated and made more
modular by being moved to its own class. Also refactored a couple of the
helper methods.
2013-06-16 15:31:32 -07:00
Rafael Mendonça França
0f89689b23 Merge pull request #10964 from nashby/collection-html-options
collection tags accept html attributes as the last element of collection
2013-06-16 09:35:18 -07:00
Vasiliy Ermolovich
782cee5377 collection tags accept html attributes as the last element of collection 2013-06-16 17:58:34 +03:00
Rafael Mendonça França
76462a8543 Merge pull request #10960 from pacoguzman/fix-build-due-to-10727
Fix build after #10727
2013-06-15 18:47:12 -07:00
Paco Guzman
20bd16330c Rewind StringIO instances before be parsed again 2013-06-16 00:32:33 +02:00
Paco Guzman
e04d9538ea Use xml instead already parsed xml 2013-06-16 00:28:16 +02:00
Rafael Mendonça França
eabbfb2348 Merge pull request #10727 from pacoguzman/fix-xml-mini-tests
Fix XmlMini different backends tests
2013-06-15 13:06:49 -07:00
Xavier Noria
c0058aec8f Merge pull request #10954 from arunagw/update_docs_for_const_regexp
Updated the doc for const_regexp [ci skip]
2013-06-15 11:53:40 -07:00
Arun Agrawal
f9086d63cd Updated the doc for const_regexp [ci skip] 2013-06-15 19:14:51 +02:00
Rafael Mendonça França
3b7192d21e Merge pull request #10949 from alexpeattie/update_html_boolean_attrs
Update HTML boolean attributes per the HTML 5.1 spec
2013-06-15 06:56:50 -07:00
Rafael Mendonça França
fe01752418 Merge pull request #10533 from vipulnsward/fix_test
Fix test, addresss => address
2013-06-15 06:27:19 -07:00
Vipul A M
e9177816ff Make test name descriptive and add reference to original regression commit 2013-06-15 18:39:06 +05:30
Yves Senn
00519985f3 Merge pull request #10907 from senny/fixtures_and_database_url
fixture setup does not rely on `AR::Base.configurations`.
2013-06-15 06:06:53 -07:00
Yves Senn
6d10d64cba fixture setup does not rely on AR::Base.configurations.
As you can also configure your database connection using `ENV["DATABASE_URL"]`,
the fixture setup can't reply on the `.configurations` Hash.

As the fixtures are only loaded when ActiveRecord is actually used
(`rails/test_help.rb`) it should be safe to drop the check for an existing configuration.
2013-06-15 14:58:38 +02:00
Rafael Mendonça França
be4fac3c0c Merge pull request #10955 from arunagw/jruby_json_not_required
'json' gem is no more required under JRuby
2013-06-15 05:51:09 -07:00
Yves Senn
1fb25b719d Merge pull request #10925 from senny/10917_test_to_prevent_regression
regression test + mysql2 adapter raises correct error if conn is closed.
2013-06-15 05:44:08 -07:00
Yves Senn
36bc4f5a02 regression test + mysql2 adapter raises correct error if conn is closed. 2013-06-15 14:35:14 +02:00
Yves Senn
7078ec3f98 cleanup, remove trailing whitespace from AR changelog 2013-06-15 14:34:55 +02:00
Arun Agrawal
f50459000a 'json' gem is no more required under JRuby 2013-06-15 13:05:07 +02:00
Yves Senn
c3adb313aa Merge pull request #10953 from acapilleri/fix_typos
fix typos
2013-06-15 03:24:38 -07:00
Angelo Capilleri
f7b9a9a836 fix typos 2013-06-15 09:14:28 +02:00
Carlos Antonio da Silva
a9a33c59f6 Fix AS changelog [ci skip] 2013-06-14 19:53:58 -03:00
Alex Peattie
a89bdc04ba Update the HTML boolean attributes per the HTML 5.1 spec
- Add attributes `allowfullscreen`, `default`, `inert`, `sortable`,
`truespeed`, `typemustmatch`.
- Fix attribute `seamless` (previously misspelled `seemless`).
- Use `assert_dom_equal` instead of `assert_equal` in test.
2013-06-14 23:47:21 +01:00
Carlos Antonio da Silva
5529ff8d91 Merge pull request #10950 from appscape-forks/fix-wrong-method-name
Fix wrong method name
2013-06-14 15:27:03 -07:00
Xavier Noria
9fb17c9093 Merge pull request #10946 from arunagw/build_fix_for_object_const_get_nil
We need to check exception name to be nil
2013-06-14 15:24:02 -07:00
Arun Agrawal
07d8294b94 Changing const_regexp to check for constant name.
We need to return Regexp.escape(camel_cased_word)
if the split is blank.
2013-06-15 00:16:05 +02:00
Martin Schürrer
53edda2235 valid_app_const? -> valid_const? 2013-06-15 00:13:50 +02:00
Rafael Mendonça França
6e34601653 Add CHANGELOG entry for #10740
[ci skip]
2013-06-14 17:56:49 -03:00
Rafael Mendonça França
78234fe605 Merge pull request #10740 from mrsimo/hash-with-indifferent-access-select
HashWithIndifferentAccess#select working as intended
2013-06-14 13:53:31 -07:00
Rafael Mendonça França
f7114754b1 Merge pull request #10898 from dmitry/find_first_refactor_duplication
Refactored ActiveRecord `first` method to get rid of duplication.
2013-06-14 13:17:42 -07:00
Piotr Sarnacki
067e1505d4 Properly namespace DatabaseTasks 2013-06-14 18:51:14 +02:00
Steven Yang
8867e16a60 correct documentation about active_record behavior 2013-06-15 00:34:10 +08:00
Piotr Sarnacki
6553df05bd Use DatabaseTasks.env instead of Rails.env in databases.rake 2013-06-14 17:29:31 +02:00
Yves Senn
add318c7f4 Merge pull request #10937 from prathamesh-sonpatki/except_example
Added an example of the query without except before the example with except
2013-06-14 04:12:48 -07:00
Prathamesh Sonpatki
cbde6f56ae Added an example of the query without except before the example with except 2013-06-14 15:19:53 +05:30
Xavier Noria
85bb7d9af1 Merge pull request #10943 from killthekitten/10932_constantize_empty
Fix #10932. Treat "" and "::" as invalid on constantize
2013-06-14 02:19:25 -07:00
Nikolay Shebanov
7fd36f307a Fix #10932. Treat "" and "::" as invalid on constantize 2013-06-14 11:20:15 +04:00
Guillermo Iguaran
90a6059dd2 Merge pull request #10833 from hone/remove_initialize_on_precompile
`initialize_on_precompile` is not used anymore.
2013-06-13 19:22:57 -07:00
Terence Lee
2d5a6de4e2 initialize_on_precompile is not used anymore. 2013-06-13 16:33:39 -07:00
Aaron Patterson
383842d079 quoted table name is also cached 2013-06-13 16:07:11 -07:00
Aaron Patterson
96925570a1 table name is cached on the class, so stop caching twice 2013-06-13 16:06:41 -07:00
Aaron Patterson
f4767bc844 calculate types on construction 2013-06-13 16:03:40 -07:00
Aaron Patterson
bf966ad8ee only cache the primary key column in one place 2013-06-13 15:57:48 -07:00