aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Update documentation for setting asset_host to a Proc, mention that the ↵Manuel Meurer2014-05-311-1/+4
| | | | request parameter might not be supplied [ci skip]
* Merge pull request #15437 from sgrif/sg-missing-test-caseYves Senn2014-05-311-0/+2
|\ | | | | Add missing test case for writing unknown attributes
| * Add missing test case for writing unknown attributesSean Griffin2014-05-301-0/+2
| |
* | Merge pull request #15440 from ilikepi/pr_docs_activesupport_hwia_dupZachary Scott2014-05-301-1/+8
|\ \ | |/ |/| HashWithIndifferentAccess#dup doc [ci skip]
| * HashWithIndifferentAccess#dup doc [ci skip]James Blanding2014-05-301-1/+8
|/ | | | | The phrase "exact copy" in the existing docmentation is somewhat misleading.
* Merge pull request #15431 from sgrif/sg-bad-serialization-test-casesRafael Mendonça França2014-05-301-53/+17
|\ | | | | Update some bad test cases for serialized columns
| * Update some bad test cases for serialized columnsSean Griffin2014-05-301-53/+17
|/ | | | | | | | | | | | The first case was not testing what the issue mentioned actually was (A subclass of a class with serialized attributes does not serialize when they come from the database). The second case was a bad coder. It would fail if the model was `dup`ed, or if the the model was loaded from the database and then saved again. The third case wasn't testing anything that wasn't covered by the second (and was also a bad coder for the same reasons as the second).
* Merge pull request #15427 from sgrif/sg-rename-attribute-ivarsRafael Mendonça França2014-05-3013-44/+44
|\ | | | | Rename attribute related instance variables to better express intent
| * Rename attribute related instance variables to better express intentSean Griffin2014-05-3013-44/+44
| | | | | | | | | | | | | | | | | | `@attributes` was actually used for `_before_type_cast` and friends, while `@attributes_cache` is the type cast version (and caching is the wrong word there, but I'm working on removing the conditionals around that). I opted for `@raw_attributes`, because `_before_type_cast` is also semantically misleading. The values in said hash are in the state given by the form builder or database, so raw seemed to be a good word.
* | Merge pull request #15354 from sgrif/sg-properties-defaultRafael Mendonça França2014-05-303-6/+19
|\ \ | | | | | | Allow specifying a default value in overloaded properties
| * | Allow specifying a default value in overloaded propertiesSean Griffin2014-05-303-6/+19
| |/
* | Merge pull request #15426 from oggy/doc-3.2.18Zachary Scott2014-05-301-4/+5
|\ \ | |/ |/| Update guides to mention 3.2.18. [ci skip]
| * Update guides to mention 3.2.18.George Ogata2014-05-301-4/+5
|/ | | | And reword things a little to mention the specific patch release less.
* Merge pull request #15313 from ↵Rafael Mendonça França2014-05-301-0/+8
|\ | | | | | | | | andreychernih/time-with-zone-string-conversion-speed-up Speed-up TimeWithZone to String conversion
| * Speed-up TimeWithZone to String conversionAndrey Chernih2014-05-271-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I've noticed that `String(model.created_at)` is performing poorly in comparision with other fields. The source of the problem is a way `Kernel#String` works: it first tries to call `to_str` (which causes `NoMethodError` in `method_missing`) and then calls `to_s`. Performance tests: tz = Time.zone.now Benchmark.ips do |x| x.report { String(tz) } end Without this code: Calculating ------------------------------------- 572 i/100ms ------------------------------------------------- 10177.7 (±18.2%) i/s - 48620 in 5.000325s With this code: Calculating ------------------------------------- 1518 i/100ms ------------------------------------------------- 138984.2 (±10.1%) i/s - 677028 in 4.974897s
* | Change the version schema to reflect how deprecations are handledRafael Mendonça França2014-05-301-3/+3
| | | | | | | | | | | | [ci skip] We only introduce new deprecations at Minor releases.
* | Merge pull request #15425 from leafac/fix-testing-docsRafael Mendonça França2014-05-301-12/+8
|\ \ | | | | | | Update Minitest references in Testing Guide
| * | Update Minitest references in Testing GuideLeandro Facchinetti2014-05-301-12/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Guide references `test/unit`, which has been replaced by `Minitest` in all versions of Ruby supported by Rails. The following updates were performed: * The superclass of `ActiveSupport::TestCase` is no longer `MiniTest::Unit::TestCase`, but `Minitest::Test` [1]. * The preferred spelling is `Minitest`, not `MiniTest` [2]. * For a method to be a test in Minitest, its name must start with `test_`, not only `test` [3]. * Explanations about `test/unit` in Ruby 1.8 were removed in favor of more up-to-date information on `Minitest`. [1]: https://github.com/rails/rails/blob/6c2b569660c9216595d02ce6412e3bdcc7293317/activesupport/lib/active_support/test_case.rb#L18 [2]: https://github.com/seattlerb/minitest/blob/d5d43cef9a3fd4a0eea972dde125ed5ba1ddb821/lib/minitest.rb#L9 [3]: https://github.com/seattlerb/minitest/blob/d5d43cef9a3fd4a0eea972dde125ed5ba1ddb821/lib/minitest/test.rb#L62
* | | bin/setup uses `bundle check || bundle install` to improve performance.Yves Senn2014-05-301-1/+1
| | |
* | | refactor, introduce `Type#type_cast_for_schema` to cast for schema.rbYves Senn2014-05-308-26/+33
| | | | | | | | | | | | | | | | | | | | | This removes the case statement in `SchemaDumper` and gives every `Type` the possibility to control the SchemaDumper default value output. /cc @sgrif
* | | pg, support default values for enum types. Closes #7814.Yves Senn2014-05-304-2/+24
| | | | | | | | | | | | | | | This is an intermediate solution. It is related to the refactoring @sgrif is making and will change in the future.
* | | pg, `default_sequence_name` respects schema. Closes #7516.Yves Senn2014-05-303-10/+12
|/ /
* | Merge pull request #11896 from nkondratyev/fix_pg_columns_for_distinctYves Senn2014-05-303-1/+17
|\ \ | | | | | | | | | | | | | | | | | | Fixed #columns_for_distinct of postgresql adapter Conflicts: activerecord/CHANGELOG.md
| * | Fixed `columns_for_distinct` of postgresql adapterNikolay Kondratyev2013-08-153-1/+17
| | |
* | | :scissors: removed deprecated `Numeric#ago` and friendsGodfrey Chan2014-05-303-62/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replacements: 5.ago => 5.seconds.ago 5.until => 5.seconds.until 5.since => 5.seconds.since 5.from_now => 5.seconds.from_now The removed tests does not affect coverage – we have equivalent test cases in the tests for `AS::Duration`. See #12389 for the history and rationale behind this.
* | | Merge pull request #15189 from senny/bin/setupYves Senn2014-05-304-1/+34
|\ \ \ | | | | | | | | `bin/setup` script to bootstrap applications.
| * | | `bin/setup` script to bootstrap applications.Yves Senn2014-05-304-1/+34
|/ / /
* | | pg, `reset_pk_sequence!` respects schemas. Closes #14719.Yves Senn2014-05-305-11/+34
| | |
* | | pg, `PostgreSQL::Name` to hold schema qualified names.Yves Senn2014-05-304-19/+96
| | |
* | | Merge pull request #15417 from JuanitoFatas/doc/semver-of-railsZachary Scott2014-05-291-4/+23
|\ \ \ | | | | | | | | [ci skip] Document Rails' shifted semver.
| * | | [ci skip] Document Rails' shifted semver.Juanito Fatas2014-05-301-4/+23
|/ / /
* | | Mapping never actually uses @set, so rmAaron Patterson2014-05-292-4/+4
| | |
* | | no reason to make a Mapper object if the path is blankAaron Patterson2014-05-291-1/+2
| | |
* | | Merge branch 'mapper'Aaron Patterson2014-05-2912-210/+220
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * mapper: (34 commits) no more is_a checks on instantiation Path::Pattern is instantiated internally, so make the contructor require a strexp object Strexp#names is only used in a test, so rm pass the parsed path from mapper to the Strexp add an alternate constructor to Strexp that takes a string ask the strexp for the ast remove dead code disconnect path from the instance reuse the ast we already made use a parser to extract the group parts from the path pass the parsed parameters through the methods so we don't reparse or require caching code "controllers" should be a valid path name controllers with slash names are also not supported, so we can reuse the message only validate controllers golf down a bit only error handling between controller and action is the same add a test for controllers without colons move nil check to a method that yields to a block if the value is not nil translate action / controller to the desired object only one nil check on the action variable ...
| * | | no more is_a checks on instantiationAaron Patterson2014-05-292-13/+4
| | | |
| * | | Path::Pattern is instantiated internally, so make the contructor require a ↵Aaron Patterson2014-05-295-46/+49
| | | | | | | | | | | | | | | | strexp object
| * | | Strexp#names is only used in a test, so rmAaron Patterson2014-05-292-36/+0
| | | |
| * | | pass the parsed path from mapper to the StrexpAaron Patterson2014-05-292-5/+9
| | | |
| * | | add an alternate constructor to Strexp that takes a stringAaron Patterson2014-05-296-39/+41
| | | |
| * | | ask the strexp for the astAaron Patterson2014-05-292-3/+7
| | | |
| * | | remove dead codeAaron Patterson2014-05-291-1/+0
| | | |
| * | | disconnect path from the instanceAaron Patterson2014-05-291-6/+6
| | | |
| * | | reuse the ast we already madeAaron Patterson2014-05-291-9/+10
| | | |
| * | | use a parser to extract the group parts from the pathAaron Patterson2014-05-293-5/+9
| | | |
| * | | pass the parsed parameters through the methods so we don't reparse orAaron Patterson2014-05-291-38/+34
| | | | | | | | | | | | | | | | require caching code
| * | | Merge branch 'master' into mapperAaron Patterson2014-05-2922-73/+148
| |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * master: Update url to rake docs [ci skip] Name#model_name doesn't return a String object Result sets never override a model's column type [ci skip] Make last note show up in postgresql guide. Add missing `:param` option from the docs for Mapper#match [ci skip] Option discovered by @zackperdue in #14741, implemented in #5581. Add @senny's changed from #14741, including code font for `resources` options, and wrapped to 80 chars. [ci skip] Use github url for homepage of log4r [ci skip] Remove TODO. Ensure we always use instances of the adapter specific column class Fix indentation from 1b4b26f [ci skip] [ci skip] Improve form_helpers.md guide. Clear inflections after test. Remove unnecessary include for integration tests. Added documentation for the :param option for resourceful routing
| * | | | "controllers" should be a valid path nameAaron Patterson2014-05-292-1/+11
| | | | |
| * | | | controllers with slash names are also not supported, so we can reuse the messageAaron Patterson2014-05-281-6/+2
| | | | |
| * | | | only validate controllersAaron Patterson2014-05-281-15/+17
| | | | |
| * | | | golf down a bitAaron Patterson2014-05-281-8/+4
| | | | |