aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test
Commit message (Collapse)AuthorAgeFilesLines
* ActionView.url_for doesn't escape by defaultPhil Darnowsky2009-10-151-3/+13
| | | | | | | | | | | | | | | | | ActionView::Helpers::UrlHelper#url_for used to escape the URLs it generated by default. This was most commonly seen when generating a path with multiple query parameters, e.g. url_for(:controller => :foo, :action => :bar, :this => 123, :that => 456) would return http://example.com/foo/bar?that=456&amp;this=123 escaping an ampersand that shouldn't be escaped. This is both wrong and inconsistent with the behavior of ActionController#url_for, and is changed. Signed-off-by: Michael Koziarski <michael@koziarski.com>
* Start adding configuration to ActionView instead of using constants.Yehuda Katz2009-10-143-0/+16
| | | | | | | By using config rather than hardcoded constants, we can evolve the configuration system over time (we'd just need to update the config method with more robust capabilities and all consumers would get the capabilities with no code changes)
* CookieJar#delete should return the key's value, consistent with a HashJeffrey Hardy2009-10-142-2/+9
| | | | Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
* Kill mock routing assertion that tests router implementationJoshua Peek2009-10-101-13/+0
|
* Fix failing safe buffer test. We don't patch CGI.escapeHTML, only ERB:Util.Joshua Peek2009-10-101-1/+1
|
* Move safe buffer into test/templateJoshua Peek2009-10-101-0/+0
|
* Relative url generations are covered more thoroughly by url rewriter testsJoshua Peek2009-10-101-12/+0
|
* Add define another "stuff" controller to support routing testsJoshua Peek2009-10-101-0/+1
|
* Drop implementation specific routing test assertionsJoshua Peek2009-10-101-3/+0
|
* Add define a "stuff" controller in fixtures to support routing testsJoshua Peek2009-10-101-0/+1
|
* API change: content_tag_for outputs prefixed class nameJoshua Peek2009-10-081-1/+1
|
* Switch to on-by-default XSS escaping for rails.Michael Koziarski2009-10-0812-6/+121
| | | | | | | | | | | | 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.
* Coerce all out going body parts to StringsJoshua Peek2009-10-052-0/+41
|
* Only draw default route onceJoshua Peek2009-10-031-22/+37
|
* Use with_routing helper in tests instead of modifying global route setJoshua Peek2009-10-034-101/+125
|
* Redraw default routes on all internal integration tests. We don't need ↵Joshua Peek2009-10-0315-41/+34
| | | | SimpleRouteCase anymore
* Avoid creating new controller constants during test runtime. All routable ↵Joshua Peek2009-10-032-68/+21
| | | | controllers should be defined beforehand.
* Moved shared form helper models into fake_modelsJoshua Peek2009-10-033-99/+98
|
* Changing directories during the test breaks file loading when ran by itselfJoshua Peek2009-10-032-32/+22
|
* Don't load rubygems for isolated testsJoshua Peek2009-10-031-2/+3
|
* Move improved isolated test runner to APJoshua Peek2009-10-031-0/+16
|
* File extra test folders into controller, dispatch, or templateJoshua Peek2009-10-0325-17/+16
|
* Add custom "with_routing" to internal tests to fix reseting session after usingJoshua Peek2009-10-0314-20/+30
| | | | with_routing. This only affects our internal AP tests.
* Ported the new ActionView::TestCase from 2-3-stable to master [#3260Erik Ostrom2009-09-284-11/+175
| | | | | | | | | | | | | | | | | state:resolved] The test case now mimicks the template environment more closely, so it's possible to use render, load helper dependencies. This also fixes assert_select, and similar assertions. Because view tests and helpers generally don't render full templates assert_select looks first in rendered and then in output_buffer to find the rendered output. Additional `master'-only changes: Made the Action Pack Rakefile run the ActionView::TestCase tests, and made ActionView::Rendering#_render_text always return a string. Signed-off-by: Joshua Peek <josh@joshpeek.com>
* Introduce :almost keyword for distance_of_time_in_words. Make 1.75 days - 2 ↵John Trupiano2009-09-282-21/+37
| | | | | | | days return '2 days'. Signed-off-by: Michael Koziarski <michael@koziarski.com> [#3266 state:committed]
* Enhancing distance_of_time_in_words to prefix year output with over and ↵Jay Pignata2009-09-281-7/+8
| | | | | | | about depending upon how many months have elapsed Signed-off-by: Michael Koziarski <michael@koziarski.com> [#3106 state:committed]
* Move middleware and route configuration from AC::Dispatcher to Rails ↵Joshua Peek2009-09-261-7/+5
| | | | application object
* Allow setting a default application for all integration testsJoshua Peek2009-09-262-7/+8
|
* Allow integration test rack app to be set with "@app" ivar instead of using ↵Joshua Peek2009-09-267-25/+19
| | | | open_session
* Fix skipping memcache tests if a memcache server isn't runningJoshua Peek2009-09-261-0/+4
|
* Remove deprecated calls to Dispatcher.to_prepareJoshua Peek2009-09-261-10/+5
|
* Move default middleware stack into initializerJoshua Peek2009-09-263-13/+7
|
* AC::Dispatcher is the default app, don't need to set itJoshua Peek2009-09-261-4/+0
|
* Clean up session integration tests so they don't reference AC::DispatcherJoshua Peek2009-09-263-52/+15
|
* Move Rails::Static into ActionDispatchJoshua Peek2009-09-264-0/+38
|
* Fix generic url rewriter in integration testsJoshua Peek2009-09-251-0/+9
|
* Restore split between require-time and runtime load path mungery. Simplifies ↵Jeremy Kemper2009-09-241-1/+1
| | | | vendor requires.
* Resurrect AC::Benchmarking [#3140 state:resolved]Joshua Peek2009-09-241-12/+11
|
* Move helpers specific to functional tests out of TestProcess into AC::TestCaseJoshua Peek2009-09-231-11/+3
|
* Move integration test runner into ActionDispatchJoshua Peek2009-09-231-2/+0
|
* Fixes Sam Ruby tests suite.José Valim2009-09-211-3/+2
| | | | Signed-off-by: Yehuda Katz <wycats@gmail.com>
* Use NewCallbacks on ActionDispatch::Callbacks.José Valim2009-09-201-8/+10
|
* Add Orchestra instrumentation to fragment and page caching.José Valim2009-09-201-3/+8
|
* Ensure changes to I18n locale get reset during testsJoshua Peek2009-09-193-14/+14
|
* Follow short name convention for test folder and just call it "abstract"Joshua Peek2009-09-1914-0/+0
|
* Merge bundler helper into abstract_unitJoshua Peek2009-09-192-12/+8
|
* Namespace TestControllers inside their test case classJoshua Peek2009-09-194-199/+216
|
* Avoid conflict with a "MetalTest" module used in testsJoshua Peek2009-09-191-1/+1
|
* All on one base, don't need thisJoshua Peek2009-09-191-3/+0
|
* Avoid conflicts with another ContentTypeController used in testingJoshua Peek2009-09-195-8/+7
|