Commit Graph

219 Commits

Author SHA1 Message Date
Rafael Mendonça França
921576b1d9 Merge pull request #17862 from lucasmazza/lm-hide-action
`_generate_paths_by_default` should always be private.
2014-12-02 11:40:11 -02:00
Erik Michaels-Ober
d1374f99bf Pass symbol as an argument instead of a block 2014-11-29 11:53:24 +01:00
Guo Xiang Tan
76f5a9afb3 Remove session to allow with_routing to be called twice.
Fixes: https://github.com/rails/rails/issues/16814
2014-11-05 23:38:02 +08:00
Godfrey Chan
2b41343c34 Default to sorting user's test cases for now
Goals:

1. Default to :random for newly generated applications
2. Default to :sorted for existing applications with a warning
3. Only show the warning once
4. Only show the warning if the app actually uses AS::TestCase

Fixes #16769
2014-09-08 05:32:16 -07:00
Matthew Draper
2f52f96988 Leave all our tests as order_dependent! for now
We're seeing too many failures to believe otherwise.

This reverts commits bc116a55ca3dd9f63a1f1ca7ade3623885adcc57,
cbde413df3839e06dd14e3c220e9800af91e83ab,
bf0a67931dd8e58f6f878b9510ae818ae1f29a3a, and
2440933fe2c27b27bcafcd9019717800db2641aa.
2014-09-02 23:55:34 +09:30
Agis-
b7ab73a4e2 Use system /tmp when testing actionpack
c64bff2c87
added support and enabled parallel execution of the actionpack tests.

However it introduced c64bff2c87
since one cannot connect to a socket file that's inside a Vagrant synced folder
due to security restrictions, and DRb tries to.

Also rename the temporary files to make it obvious that they're rails-related,
since now they're placed outside the project's directory.

Fixes c64bff2c87
2014-08-22 22:03:41 +03:00
Aaron Patterson
efb835c9c0 UnexpectedErrors may reference exceptions that can't be dumped
UnexpectedError exceptions wrap the original exception, and the original
exception may contain a reference to something that can't be marshal
dumped which will cause the process to die.
2014-08-13 14:22:49 -07:00
Akira Matsuda
bc116a55ca AM, AP, AV, and AMo tests are already order_independent! 2014-08-13 21:25:10 +09:00
Rafael Mendonça França
e81f3c210e Nobody sucks so nobody should call this awful method name 2014-08-12 10:51:41 -03:00
Akira Matsuda
6ffb29d24e users_dont_suck_but_only_we_suck_and_only_our_tests_are_order_dependent!
Calling ActiveSupport::TestCase.i_suck_and_my_tests_are_order_dependent! in AS::TestCase makes
everyone's tests order dependent, which should never be done by the framework.
2014-08-12 19:37:04 +09:00
Rafael Mendonça França
decb83b9fd Use PROCESS_COUNT to define the number of parallel executors 2014-07-23 14:40:43 -03:00
Aaron Patterson
0b773c30fb specify N=0 to prevent parallel tests (just run tests on the main process) 2014-07-23 10:38:52 -07:00
Rafael Mendonça França
08754f12e6 Merge branch 'rm-remove-mocha'
Conflicts:
	actionpack/test/abstract_unit.rb
2014-07-19 18:17:13 -03:00
Rafael Mendonça França
fd6aaaa0c3 Stop requiring mocha automatically
We are planning to remove mocha from our test suite because of
performance problems. To make this possible we should stop require mocha
on ActionSupport::TestCase.

This should not affect applications since users still need to add mocha
to Gemfile and this already load mocha.

Added FIXME notes to place that still need mocha removal
2014-07-19 17:35:12 -03:00
Aaron Patterson
d4c8068675 reporting is only done in one thread, so we can safely remove the lock
(I think)
2014-07-17 18:43:46 -07:00
Aaron Patterson
5751b7ea58 pass the test reporter by reference
this prevents the array from being dumped as a DRbObject so we can
reduce communication with the server.  the reporter should always exist
on the server side, so we don't have to worry about GC
2014-07-17 14:45:30 -07:00
Aaron Patterson
8d126c9424 do not restart the service, just stop it 2014-07-17 14:04:55 -07:00
Aaron Patterson
d548a36c8f only parallelize on forking systems 2014-07-17 14:04:55 -07:00
Aaron Patterson
c64bff2c87 [EXPERIMENTAL] run actionpack tests in parallel
only on forking systems though.  Feel free to revert this if it causes
problems.
2014-07-17 12:08:41 -07:00
Aaron Patterson
212057b912 pass the route name to define_url_helper
this allows us to avoid 2 hash allocations per named helper definition,
also we can avoid a `merge` and `delete`.
2014-07-17 11:21:17 -07:00
Aaron Patterson
7880f39e1d Fix 1.9. uggghhhhhh get it together @tenderlove 💣 2014-07-15 18:43:47 -07:00
Aaron Patterson
993ca82d70 fix for 1.9 kwargs syntax 2014-07-15 18:20:50 -07:00
Aaron Patterson
f3c1832ad4 stop passing recall to url_for 2014-07-15 15:53:00 -07:00
Aaron Patterson
3ef98a1439 fix warnings 2014-07-15 15:24:23 -07:00
Aaron Patterson
8eb7bcb6e5 stop calling url_for with recall parameters and actually use a request 2014-07-15 15:19:41 -07:00
Matthew Draper
29f8eae3fa Merge pull request #15061 from tgxworld/remove_unnecessary_include
Remove unnecessary include for integration tests.
2014-05-29 21:33:12 +09:30
Aaron Patterson
348af15c33 _recall should be set to a hash or not set
Then we can avoid nil checks
2014-05-13 17:21:55 -07:00
Guo Xiang Tan
da290fae09 Remove unnecessary include for integration tests. 2014-05-11 16:02:12 -07:00
Gaurish Sharma
35e56f6fa5 standardize on jruby_skip & rbx_skip
This Adds helpers(jruby_skip & rbx_skip). In Future, Plan is to use
these helpers instead of calls directly to
RUBY_ENGINE/RbConfig/JRUBY_VERSION
2014-01-13 19:51:47 +05:30
Akira Matsuda
ccc1a7b7b0 Unused classes in AP tests 2013-12-25 18:10:56 +09:00
Carlos Antonio da Silva
6802196a6b Disable available locales checks to avoid warnings running the tests 2013-12-17 09:05:41 -02:00
Carlos Antonio da Silva
d6eda3ef3c Remove missing integration points of AV extraction 2013-12-05 11:39:56 +01:00
Łukasz Strzałkowski
21c5f2845d Remove RenderERBUtils from AP (only AV use it) 2013-08-25 11:39:10 +02:00
Łukasz Strzałkowski
37d77f6b9d Remove AV::TestCase from AP 2013-08-25 11:39:10 +02:00
Łukasz Strzałkowski
3fd2e72477 Load AV::Layouts dynamicly via railties 2013-08-25 11:39:10 +02:00
Łukasz Strzałkowski
8e3413d410 Create AbstractController::Rendering interface
This interface should be use when implementing renderers.
2013-08-25 11:39:09 +02:00
Łukasz Strzałkowski
8c2c95e5d2 Fix AP test suite after moving stuff to AV 2013-08-25 11:39:08 +02:00
Vipul A M
f23e7eba52 remove unused variable and assignment 2013-03-31 19:34:40 +05:30
Akira Matsuda + Koichi Sasada
b7b27fc2a3 Set Thread.abort_on_exception for the whole AS, AP, and AR tests
this would give us some more clues in case a test silently dies inside Thread
2013-01-24 20:00:45 +09:00
Rafael Mendonça França
5da4d5142a Add active_support/testing/autorun
minitest/autorun load minitest/spec polluting the global namespace with
the DSL that we don't want on Rails
2012-12-31 13:57:24 -03:00
Rafael Mendonça França
ccecab3ba9 Remove observers and sweepers
They was extracted from a plugin.

See https://github.com/rails/rails-observers

[Rafael Mendonça França + Steve Klabnik]
2012-11-28 22:46:49 -02:00
Rafael Mendonça França
d0c25f253f Define a SynchronousQueue for test in Action Pack.
We don't need to rely on rails/queueing in Action Pack tests
2012-09-12 15:33:42 -03:00
Arun Agrawal
a28efd8ac6 Fix build Rails.queue
see 34b23e7110a3a13cf157608cefc9b5701017bf39
2012-09-12 09:50:16 +05:30
Ernie Miller
4037e31d88 Allow routing concerns to accept a callable
This allows us to make alterations to the generated routes based on the
scope of the current mapper, and otherwise allows us to move larger
blocks of concerns out of the routes file, altogether.
2012-09-03 13:13:16 -04:00
Rafael Mendonça França
546497d027 Extract common controllers to abstract_unit 2012-08-13 21:43:18 -03:00
Aaron Patterson
c63d17c2be push drawing once to it's own module 2012-08-09 14:50:27 -07:00
Aaron Patterson
1e8c0a29d0 refactor the before_setup hooks to a module 2012-08-09 14:50:26 -07:00
Aaron Patterson
0b29c7bb7b switch callbacks to minitest hooks 2012-08-09 14:50:26 -07:00
Bogdan Gusiev
d89161e7cc Renamed _path_segments to _recall 2012-08-04 14:55:00 +03:00
Santiago Pastorino
449039a86d Remove ActionDispatch::Head middleware in favor of Rack::Head
Closes #7110 there's more work to do on rack-cache issue 69
2012-07-23 14:34:13 -03:00