aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Make `driven_by` overridableFumiaki MATSUSHIMA2017-03-292-6/+13
| | | | | | | | | | | | | | | | | | | | | | Sometimes we want to use rack_test partially instead of selenium for test speed: ```ruby class ApplicationSystemTestCase < ActionDispatch::SystemTestCase driven_by :selenium, using: :chrome, screen_size: [1400, 1400], options: {url: "http://chrome:4444/wd/hub"} end class WithJavaScriptTest < ApplicationSystemTestCase end class WithoutJavaScriptTest < ApplicationSystemTestCase driven_by :rack_test end ``` In the abobe case, `WithoutJavaScriptTest` uses selenium because `SystemTestCase` calls superclass' driver on `#initialize` (`self.class.superclass.driver.use`). Using `class_attribute` can handle inherited `driven_by`.
* Merge pull request #28052 from kamipo/make_internal_methods_to_privateRafael França2017-03-2812-185/+181
|\ | | | | Make internal methods to private
| * Make internal methods to privateRyuta Kamizono2017-03-2712-185/+181
| |
* | Use keyword arguments instead of hashRafael Mendonça França2017-03-282-9/+11
| |
* | Merge pull request #28480 from ↵Rafael Mendonça França2017-03-285-21/+81
|\ \ | | | | | | | | | | | | | | | mubashirhanif/add_keep_id_suffix_option_to_humanize_new Add keep id suffix option to humanize new
| * | Added options hash to titleize method and keep_id_suffix option to humanizeMubashir Hanif2017-03-215-21/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | some documentation remove extra whitespace. Added id in the middle test case and corrected some testcases. Some Coding standard guidelines corrections as suggested by codeclimate. Some more corrections suggested by codeclimate.
* | | starts_with? is removed in Ruby 2.4Rafael Mendonça França2017-03-281-1/+1
| | |
* | | Merge pull request #1 from radiospiel/tickets/26955-listen-pathsRafael Mendonça França2017-03-281-0/+5
|\ \ \ | | | | | | | | | | | | No longer listens to dirs outside of the app directory.
| * | | No longer listens to dirs inside of installed gemseno2016-11-081-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | rails5 uses the listen gem to watch for changes from autoload directories and from i18n directories. Changes there would be reflected by the running app, in development mode usually. However, files outside of the application directory or locally installed gems should not change during development, and rails does not need to reflect changes there if they do. This change makes sure only those paths that do not originate from the app itself are watched. This can help especially with the situation on OSX, where rb-fsevent - which implements file watching - is quite a resource hog.
* | | | Merge pull request #28584 from bogdanvlviv/errors-keys-values-fixRafael França2017-03-283-11/+52
|\ \ \ \ | | | | | | | | | | Fix ActiveModel::Errors #keys, #values
| * | | | Fix ActiveModel::Errors #keys, #valuesbogdanvlviv2017-03-283-11/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before: person.errors.keys # => [] person.errors.values # => [] person.errors[:name] # => [] person.errors.keys # => [:name] person.errors.values # => [[]] After: person.errors.keys # => [] person.errors.values # => [] person.errors[:name] # => [] person.errors.keys # => [] person.errors.values # => [] Related to #23468
* | | | | Merge pull request #28514 from y-yagi/follow_up_to_28056Andrew White2017-03-281-8/+10
|\ \ \ \ \ | | | | | | | | | | | | Fix store accessors in parameters test
| * | | | | Fix store accessors in parameters testyuuji.yaginuma2017-03-221-8/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * The method name must be `stored_attributes`, not `stores_attributes`. * `attribute_names` must return a non-empty value. Because `stored_attributes` is not checked if `attribute_names` is empty. Follow up to #28056
* | | | | | Merge pull request #28549 from jess/patch-1Rafael França2017-03-281-0/+1
|\ \ \ \ \ \ | |_|/ / / / |/| | | | | make it clear how to enable caching
| * | | | | add proper punctuationJess Brown2017-03-231-1/+1
| | | | | |
| * | | | | make it clear how to enable cachingJess Brown2017-03-231-0/+1
| | | | | | | | | | | | | | | | | | since this is a new change, many will be coming here to toggle the true/false config and not find it. This will allow them to quickly implement the change.
* | | | | | Return unmapped timezones from `country_zones`Andrew White2017-03-282-5/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a country doesn't exist in the MAPPINGS hash then create a new `ActiveSupport::Timezone` instance using the supplied timezone id. Fixes #28431.
* | | | | | No need to duplicate 5-1-stable CHANGELOG. [ci skip]Yves Senn2017-03-281-8/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `master` changelog refer back to the `5-1-stable` changelog as a base. No need to duplicate backported entries in the changelogs on `master`.
* | | | | | Fix the tests to test what they should be testingRafael Mendonça França2017-03-271-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With Rack::Test the headers needs to match the `HTTP_` format. The tests were passing before because they are not asserting the response was a cache hit.
* | | | | | Make sure that ActionController::Api can include helpersRafael Mendonça França2017-03-271-0/+26
| | | | | | | | | | | | | | | | | | | | | | | | Closes #28554
* | | | | | Merge pull request #28557 from ↵Rafael França2017-03-273-1/+56
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | y-yagi/remove_unnecessary_files_to_api_applications_when_app_task_task_executed Remove unnecessary files to API-only Applications when `app:task` task executed
| * | | | | | Remove unnecessary files to API-only Applications when `app:task` task executedyuuji.yaginuma2017-03-243-1/+56
| | | | | | |
* | | | | | | Merge pull request #28546 from claudiob/drop-j-optionRafael Mendonça França2017-03-272-16/+0
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Remove -j (--javascript) option from `rails new`
| * | | | | | | Remove -j (--javascript) option from `rails new`claudiob2017-03-233-16/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The "-j" option was added 5 years ago (https://github.com/rails/rails/commit/d9c39c3a) when we wanted to support prototype-rails and jquery-rails. Prototype is not as popular and jQuery is not a requirement anymore. Still the "-j" option can be used to install *any* gem that ends in "-rails". This "might" open security issues and does not bring great benefits anymore. If you know which "-rails"-ending gem you want to install, you can manually add it to the Gemfile just like any other gem.
* | | | | | | | Apply the log_level defaultRafael Mendonça França2017-03-271-7/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since 4.2 the default log level in production is now debug. We removed the deprecation in c2e865849beadd99866e521a93d733da7d1b5255 but we don't reflected the default value. We are not appling it. Closes #28558
* | | | | | | | Merge pull request #28050 from namusyaka/avoid-converting-int-into-floatRafael Mendonça França2017-03-273-0/+15
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | Avoid converting integer as a string into float
| * | | | | | | | Avoid converting integer as a string into floatnamusyaka2017-02-183-0/+14
| | | | | | | | |
* | | | | | | | | Merge pull request #28488 from kamipo/preprocess_association_query_handlingRafael França2017-03-271-13/+8
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | Preprocess association query handling in predicate builder
| * | | | | | | | | Always need to extract `value.bound_attributes` if `value.is_a?(Relation)`Ryuta Kamizono2017-03-251-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Because `RelationHandler` uses `value.arel`.
| * | | | | | | | | Preprocess association query handling in predicate builderRyuta Kamizono2017-03-201-11/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently association query is handled as a postprocess. This has two problems. 1. When `value` is a `Hash`, we need to skip the postprocess using `next`. 2. `can_be_bound?` should return false if `table.associated_with?(column_name)` is true (pass to the postprocess). These are unneeded if preprocessing association query handling.
* | | | | | | | | | Merge pull request #27636 from ↵Rafael França2017-03-2725-98/+191
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | mtsmfm/disable-referential-integrity-without-superuser-privilege-take-2 Use `SET CONSTRAINTS` for `disable_referential_integrity` without superuser privileges (take 2)
| * | | | | | | | | | Load :author_addressesYasuo Honda2017-03-261-1/+1
| | | | | | | | | | |
| * | | | | | | | | | Use `SET CONSTRAINTS` for `disable_referential_integrity` without superuser ↵Fumiaki MATSUSHIMA2017-03-2624-97/+190
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | privileges (take 2) Re-create https://github.com/rails/rails/pull/21233 eeac6151a5 was reverted (127509c071b4) because it breaks tests. ---------------- ref: 72c1557254 - We must use `authors` fixture with `author_addresses` because of its foreign key constraint. - Tests require PostgreSQL >= 9.4.2 because it had a bug about `ALTER CONSTRAINTS` and fixed in 9.4.2.
* | | | | | | | | | | Merge pull request #28485 from quantumlicht/fix_migrate_with_empty_versionRafael França2017-03-274-3/+32
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | fix migrate with empty version
| * | | | | | | | | | | Fixes #28359Philippe Guay2017-03-264-3/+32
| | |_|_|_|_|_|_|_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add stronger assertions to rake migration tasks to make sure the user is providing a numeric VERSION An empty string was getting converted to version = 0. This would in turn pass the presence check. Address linting warning Add test for rake task and refactor code to meet expectations In particular passing VERSION=0 should not raise an error. Addressed Comments for PR #28485. Trimmed empty lines + change of wording for error message Adjust test for change of wording in error message Change condition to follow rails idioms
* | | | | | | | | | | Merge pull request #28577 from ↵Rafael França2017-03-272-0/+6
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | y-yagi/do_not_display_hidden_namespaces_in_destroy_command_help Do not show hidden namespaces in destroy commnad help
| * | | | | | | | | | | Do not show hidden namespaces in destroy commnad helpyuuji.yaginuma2017-03-272-0/+6
| |/ / / / / / / / / /
* | | | | | | | | | | Use the stale branchRafael Mendonça França2017-03-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ci skip]
* | | | | | | | | | | Add probot/stale configurationRafael Mendonça França2017-03-271-0/+24
| | | | | | | | | | |
* | | | | | | | | | | Merge pull request #28367 from ptoomey3/ignore-disabled-buttonsAaron Patterson2017-03-273-1/+38
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Prevent ujs event propagation if element disabled when event chain begins
| * | | | | | | | | | | Prevent event propogation if element is disabled when event chain begins.Patrick Toomey2017-03-093-1/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The existing UJS event behavior relies on browsers not sending events for various events when an element is disabled. For example, imagine the following: <button type="submit" disabled="disabled">Click me</button> The above button is disabled, so browsers will not trigger a click event and all UJS behavior is prevented. However, imagine a button like this: <button type="submit" disabled="disabled"><strong>Click me</strong></button> The above is treated differently by browsers such as Chrome/Safari. These browsers do not consider the strong tag to be disabled, and will trigger click events. UJS has logic to walk up the DOM to find an associated element subject to UJS behavior. But, this logic does not take into account the disabled status of the element. I originally thought we could simply change the selectors used to match elements to ignore disabled elements. However, UJS disables some elements as part of the event chain. So, an element might match early in the chain and then fail to match later. Instead of changing the selectors I added a callback to the chain that calls `stopEverything` if an element is disabled when the event chain begins.
* | | | | | | | | | | | Merge pull request #28541 from ota42y/fix/gemfile_generator_fixEileen M. Uchitelle2017-03-274-2/+30
|\ \ \ \ \ \ \ \ \ \ \ \ | |_|/ / / / / / / / / / |/| | | | | | | | | | | ignore system test gems on Gemfile when execute with --skip-test option
| * | | | | | | | | | | ignore system test gems on Gemfile when execute with --skip-test optionota42y2017-03-274-2/+30
| | |_|_|_|_|/ / / / / | |/| | | | | | | | |
* | | | | | | | | | | minor CHANGELOG formatting changes. [ci skip]Yves Senn2017-03-262-4/+2
| | | | | | | | | | |
* | | | | | | | | | | add field ids when generating a scaffold form.Yves Senn2017-03-264-7/+20
| |_|/ / / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a follow up to a6d065e. When using `form_with` you must supply field ids manually. Since the scaffold generator is using labels we need to make sure that they are linked up properly.
* | | | | | | | | | Bump from h3 to h2 tagJon Moss2017-03-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | "3 Days before release" should an h2, like the rest of the day headings. All of the steps are h3 tags. [ci skip]
* | | | | | | | | | Small grammar fixJon Moss2017-03-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add apostrophe. [ci skip]
* | | | | | | | | | Small grammar fixJon Moss2017-03-251-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add necessary commas. [ci skip]
* | | | | | | | | | Update middleware listJon Moss2017-03-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Taken from `bin/rails about` run on a v5.1.0.rc1 application. [ci skip]
* | | | | | | | | | Upgrade various Rails 5.0 references to 5.1Jon Moss2017-03-254-12/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | RC1 is out, `5-1-stable` has been created, figured it was time to start updating this stuff :) [ci skip]