aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/template/test_case_test.rb
Commit message (Collapse)AuthorAgeFilesLines
* config should always be an AS::InheritableOptions object. Closes #1992Santiago Pastorino2011-07-081-0/+4
|
* removed deprecated methods, and related tests, from ActionPackJosh Kalderimis2011-05-241-16/+0
|
* Move prefixes to view paths as they are now a lookup context dependency.José Valim2011-05-041-0/+4
|
* fixing space errorsAaron Patterson2011-01-171-1/+1
|
* Allow view in AV::TestCase to access it's controller helpers methodsSantiago Pastorino2011-01-121-0/+21
|
* Rename _assigns to view_assigns in AV::TCDavid Chelimsky2010-10-031-0/+31
| | | | | | | | | - also add tests - also deprecate _assigns [#5751 state:resolved] Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
* Use parentheses when using assert_match followed by a regexp to avoid warnings.Emilio Tagua2010-09-271-3/+3
|
* Allow view helper's #initialize method to be called. [#5061 state:resolved]Carl Lerche2010-09-131-0/+13
|
* Removed deprecated RouteSet API, still many tests failPiotr Sarnacki2010-09-051-2/+2
|
* Change reference to Test::Unit::AssertionFailedError to the generic ↵David Trasbo2010-06-261-1/+1
| | | | | | ActiveSupport::TestCase::Assertion [#4987 state:commited] Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
* Expose view via the view() method in AV::TestCase::BehaviorDavid Chelimsky2010-06-231-12/+16
| | | | | | | | | | - was exposed as _view, which suggested it was private - left _view as an alias of view as not to break any extensions that are relying on _view [#4932 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com>
* In ActionView::TestCase::Behavior, assign variables right beforeDavid Chelimsky2010-06-231-0/+9
| | | | | | | | | | | rendering the view. - Previously, _assigns were locked down the first time _view was referenced. [#4931 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com>
* Add support for specifying locals in view tests with assert template [#4927 ↵David Chelimsky2010-06-221-2/+16
| | | | | | state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com>
* Support render_template in view tests. Useful for specifying whichDavid Chelimsky2010-06-201-0/+8
| | | | | | | | partials are rendered under different conditions. [#4903 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com>
* Memoize the object returned by _view in ActionView::TestCase::BehaviorDavid Chelimsky2010-06-081-0/+4
| | | | | | [#4799 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com>
* In AV::TC, move protect_against_forgery? from the test_case to theDavid Chelimsky2010-06-031-0/+15
| | | | | | | | | | | | | _helper module included in the view. - ensures that protect_against_forgery? is present when a helper included in a partial that is rendered by the template under test calls it (which happens in FormTagHelper#extra_tags_for_form, for example). [#4700 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com>
* reorganize tests for AV::TCDavid Chelimsky2010-06-031-140/+138
| | | | | | | | - decouple tests from the test case class by moving them outside - split out more TestCase subs as cleaner way of avoiding bleed of class level concepts Signed-off-by: José Valim <jose.valim@gmail.com>
* Support configuration of controller.controller_path on instances ofDavid Chelimsky2010-05-261-2/+2
| | | | | | | | | | ActionView::TestCase::TestController without stubs. Just say: @controller.controller_path = "path/i/need/for/this/test" [#4697 state:resolved] Signed-off-by: José Valim <jose.valim@gmail.com>
* Move AV::TC to AV::TC::Behavior [#4678 state:resolved]David Chelimsky2010-05-241-0/+14
| | | | | | | | | | | | - enables alternative testing frameworks to include AV::TC::Behavior instead of subclassing AV::TC - also added tests and code for: - test view delegates :notice to request.flash - useful since generators generate views that use notice - test case doesn't try to include modules that are actually classes Signed-off-by: José Valim <jose.valim@gmail.com>
* Consistent routing languageJoshua Peek2010-03-301-1/+1
|
* remove_method is privateCarlhuda2010-03-041-2/+2
|
* Safely cleans up a test to avoid relying on a particular test orderwycats2010-03-041-10/+23
|
* WIP: Remove the global routerCarlhuda2010-02-251-1/+1
|
* For performance reasons, you can no longer call html_safe! on Strings. ↵Yehuda Katz2010-01-311-1/+1
| | | | | | | | | | | | Instead, all Strings are always not html_safe?. Instead, you can get a SafeBuffer from a String by calling #html_safe, which will SafeBuffer.new(self). * Additionally, instead of doing concat("</form>".html_safe), you can do safe_concat("</form>"), which will skip both the flag set, and the flag check. * For the first pass, I converted virtually all #html_safe!s to #html_safe, and the tests pass. A further optimization would be to try to use #safe_concat as much as possible, reducing the performance impact if we know up front that a String is safe.
* Use new routing dsl in testsJoshua Peek2009-12-081-2/+2
|
* Share ActionView::TestCase's output_buffer with view for concat support.Chris Hapgood2009-11-071-0/+5
| | | | | | [#3467 state:resolved] Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com>
* Make some assertions in the ActionView::TestCase tests actually do something.Chris Hapgood2009-11-071-4/+4
| | | | | | [#3468 state:resolved] Signed-off-by: Eloy Duran <eloy.de.enige@gmail.com>
* Switch to on-by-default XSS escaping for rails.Michael Koziarski2009-10-081-1/+1
| | | | | | | | | | | | This consists of: * String#html_safe! a method to mark a string as 'safe' * ActionView::SafeBuffer a string subclass which escapes anything unsafe which is concatenated to it * Calls to String#html_safe! throughout the rails helpers * a 'raw' helper which lets you concatenate trusted HTML from non-safety-aware sources (e.g. presantized strings in the DB) * New ERB implementation based on erubis which uses a SafeBuffer instead of a String Hat tip to Django for the inspiration.
* File extra test folders into controller, dispatch, or templateJoshua Peek2009-10-031-0/+172