Commit Graph

22 Commits

Author SHA1 Message Date
Alex Ghiculescu ff6881d2b2
Remove old `raise_on_missing_translations` behaviour
ref: https://github.com/rails/rails/pull/47105#issuecomment-1400843060

Removes the old `raise_on_missing_translations` accessors, that used to live [here](fee61e3abc/actionpack/lib/abstract_controller/translation.rb (L7)) and [here](5c835bd669/actionview/lib/action_view/helpers/translation_helper.rb (L15)).

Closes https://github.com/rails/rails/pull/45361
2023-09-09 19:59:49 +00:00
Rafael Mendonça França a5247bb908
Treat html suffix in controller translation
There are some difference between translation in a view and translation
in a controller.
This will treat html suffix in controller translation.

Closes #27862.

Co-authored-by: Rui Onodera <deraru@gmail.com>
Co-authored-by: Gavin Miller <gavingmiller@gmail.com>
2021-10-08 21:21:53 +00:00
Jan Klimo 0c1028f4bb Fix nil translation key lookup in controllers 2020-12-22 21:17:51 +07:00
fatkodima 6c4f3be929 Unify raise_on_missing_translations for views and controllers 2020-05-20 02:42:59 +03:00
Kir Shatrov dfcc766163 Use frozen string literal in actionpack/ 2017-07-29 14:02:40 +03:00
Matthew Draper 87b3e226d6 Revert "Merge pull request #29540 from kirs/rubocop-frozen-string"
This reverts commit 3420a14590, reversing
changes made to afb66a5a59.
2017-07-02 02:15:17 +09:30
Kir Shatrov cfade1ec7e Enforce frozen string in Rubocop 2017-07-01 02:11:03 +03:00
Vipul A M ff3c06f718
Allow translate default option to accept an array similar to i18n.t. Fixes #29441 2017-06-15 01:06:04 +05:30
Ryuta Kamizono f006de5dc5 Fix broken alignments caused by auto-correct commit 411ccbd
Hash syntax auto-correcting breaks alignments. 411ccbdab2
2016-08-10 06:36:39 +09:00
Xavier Noria 411ccbdab2 remove redundant curlies from hash arguments 2016-08-06 19:44:11 +02:00
Xavier Noria 35b3de8021 applies new string literal convention in actionpack/test
The current code base is not uniform. After some discussion,
we have chosen to go with double quotes by default.
2016-08-06 18:54:50 +02:00
Marcin Olichwirowicz 3a161e65e7 Get rid of mocha tests - part 1 2015-08-24 12:24:07 +02:00
Max Melentiev fde7344542 ActionController#translate also lookups shortcut without action name 2013-10-22 18:17:05 +04:00
printercu 40a8130bc5 ActionController#translate supports symbols
Made it similar to views helper.
2013-09-25 16:23:28 +04:00
Carlos Antonio da Silva 57b65ef416 Fix setting expected value in translation tests
It was being set to nil instead due to the wrong assignment.
2013-01-21 09:29:03 -02:00
Jens Bissinger 4685d75736 Removed ActionController::Base dependency from abstract controller translation tests. 2013-01-20 15:53:43 +01:00
Jens Bissinger 1de60c54d3 Test abstract controller's localize method. 2013-01-20 15:44:03 +01:00
Sergey Pchelincev 1b5298e805 add lazy look up in abstract controller's translate method 2012-07-18 10:33:14 +03:00
Aaron Patterson fd918fe5ed AP tests should inherit from AS::TestCase 2012-01-05 17:05:44 -08:00
Santiago Pastorino b451de0d6d Deletes trailing whitespaces (over text files only find * -type f -exec sed 's/[ \t]*$//' -i {} \;) 2010-08-14 04:12:33 -03:00
Neeraj Singh 73f0e1a842 Use assert_respond_to because it has better error messaging
[#4628 state:resolved]

Signed-off-by: José Valim <jose.valim@gmail.com>
2010-05-18 02:12:06 +02:00
José Valim 6e26be6960 Move ActionController::Translation to AbstractController::Translation. 2010-01-20 15:02:13 +01:00