aboutsummaryrefslogtreecommitdiffstats
path: root/actionview/test/template/date_helper_test.rb
Commit message (Collapse)AuthorAgeFilesLines
* Add `Style/EmptyLinesAroundMethodBody` in `.rubocop.yml` and remove extra ↵Ryuta Kamizono2017-02-121-1/+0
| | | | empty lines
* Add more rubocop rules about whitespacesRafael Mendonça França2016-10-291-46/+46
|
* Add three new rubocop rulesRafael Mendonça França2016-08-161-16/+16
| | | | | | | | Style/SpaceBeforeBlockBraces Style/SpaceInsideBlockBraces Style/SpaceInsideHashLiteralBraces Fix all violations in the repository.
* Add `Style/EmptyLines` in `.rubocop.yml` and remove extra empty linesRyuta Kamizono2016-08-071-2/+0
|
* normalizes indentation and whitespace across the projectXavier Noria2016-08-061-3/+3
|
* remove redundant curlies from hash argumentsXavier Noria2016-08-061-17/+17
|
* modernizes hash syntax in actionviewXavier Noria2016-08-061-296/+296
|
* applies new string literal convention in actionview/testXavier Noria2016-08-061-76/+76
| | | | | The current code base is not uniform. After some discussion, we have chosen to go with double quotes by default.
* Bring Boolean Attributes list for AV Tags helper upto speed with current spec.Vipul A M2016-06-281-4/+0
| | | | | | | | | This is based on https://github.com/kangax/html-minifier/blob/6b2d4536d82819143b468b41a89c700b6c61631f/src/htmlminifier.js#L197 and spec from https://www.w3.org/TR/html51/single-page.html. Couple of other changes to tests due to support update: - autobuffer has been dropped in favour of preload attribute, ref: https://msdn.microsoft.com/en-us/library/ff974743(v=vs.85).aspx - pubdate attribute has been dropped from spec, ref: https://www.w3.org/html/wg/tracker/issues/185
* Make select_year work with include_position: true option, fix #25267Marek2016-06-051-0/+7
|
* date_select helper with_css_classes option also accept a hashneumayr2016-04-051-0/+404
| | | | | | | | | | | | | | | | | | | | | | | | | | | | `date_select` helper `:with_css_classes` option now accepts a hash of strings for `:year`, `:month`, `:day`, `:hour`, `:minute`, `:second` that will extend the select type with the given css class value. ```erb <%= f.date_select :birthday, with_css_classes: { month: "my-month", year: "my-year" } %> ``` ```html <select id="user_birthday_3i" name="user[birthday(3i)]">…</select> <select id="user_birthday_2i" name="user[birthday(2i)]" class="my-month">…</select> <select id="user_birthday_1i" name="user[birthday(1i)]" class="my-year">…</select> ``` Optional, add global `html_options` to modify every select tag in the set. ```erb <%= f.date_select :birthday, with_css_classes: { month: "my-month", year: "my-year" }, { class: "my-date optional" } %> ``` Supported DateHelper methods: `select_day`, `select_month`, `select_year`, `select_hour`, `select_minute`, `select_second`, `select_datetime`, `select_time`, `time_select`, `date_select` and `datetime_select`. `:with_css_classes` option was added to the `date_select` with #7975.
* html_safe is not supposed to be public API for AV. This change removes usage ↵Vipul A M2016-01-201-1/+1
| | | | | | of html_safe in favour of raw() in AV helpers. Also changed usage of html_safe to make use of raw() instead so that the intended behaviour is verified with raw()
* deletes commented code introduced in db045db (initial commit)Tony Ta2015-12-151-17/+0
|
* deletes commented code introduced in 4673c47dTony Ta2015-12-151-5/+0
|
* making selected value to accept Hash like the default option. E.g. selected: ↵Lecky Lao2015-10-291-0/+20
| | | | | | | | {day: params[:day].to_i, month: params[:month].to_id} Adds in test test_date_select_with_selected_in_hash and change log fixes typo in CHANGELOG
* :put_litter_in_its_place: Unused methodsAkira Matsuda2015-04-251-8/+0
|
* Silence warning from requiring mathnPrem Sichanugrist2015-04-221-1/+1
| | | | | | | | | Running Action View test case currently printing out this warning: lib/mathn.rb is deprecated This should silence the warning since we really want to require this file in this test.
* Use directly TZInfo::Timezone without proxybrainopia2015-01-041-1/+1
| | | | | Since real timezone is loaded anyway in `#utc_offset` which is called during `#create`
* Duplicated Hash key :promptAkira Matsuda2014-11-191-1/+1
|
* All these tests are passing nowRafael Mendonça França2014-07-151-4/+0
|
* Change date helper tests to expect attributes with double quoted strings.Timm2014-06-161-14/+15
|
* Added related Nokogiri issue link to tests that fail with unknown encoding ↵Timm2014-06-161-4/+4
| | | | ASCII-8BIT.
* Marked some tests as pending in date_helper_test.rb.Timm2014-06-151-0/+4
|
* Fix date_select option overwriting html classesIzumi Wong-Horiuchi2014-03-241-0/+16
| | | | | with_css_classes: true option overwrites other html classes. Concatenate day month and year classes rather than overwriting.
* implements new option :month_format_string for date select helpers [Closes ↵Xavier Noria2014-02-151-0/+10
| | | | #13618]
* Remove privatizing of Fixnum#/ from assert_distance_of_time_in_wordsAlex Tambellini2013-08-051-5/+7
| | | | | | | | MRI reimplemented Date in C so it doesn't hit this division anymore while JRuby still uses the old stdlib implementation of Date so it will always hit this. With this change the actionview date_helper_test.rb tests should pass on JRuby.
* Move template tests from actionpack to actionviewPiotr Sarnacki2013-06-201-0/+3199