Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

[PATCH] ActiveSupport ts_isolated test not running

#4215

Got this require error when running this test alone.

activesupport/test/ts_isolated.rb:3:in require': no such file to load -- active_support/core_ext/kernel/reporting (LoadError)<br/>

from activesupport/test/ts_isolated.rb:3

Patch attached resolving this issue.

Reported by Sebastian Martinez · March 18th, 2010 @ 04:28 PM

State: resolved
Milestone: 3.0.2
Assigned to: José Valim José Valim
Importance: none

Activity

  1. José Valim
    José Valim

    Hey Sebastian, thanks for the patch, but the require you are trying to remove is correct. Something else is wrong. Please try a patch where you add "active_support/lib" to the $LOAD_PATH, so the current require still works.

    March 18th, 2010 @ 04:34 PM

  2. Sebastian Martinez
  3. Sebastian Martinez
    Sebastian Martinez

    The patch does not intend to remove the require, but to add the correct path to it, so it can propely find reporting.rb
    Anyway, will upload a patch where active_support/lib is added to $LOAD_PATH

    March 18th, 2010 @ 04:38 PM

  4. José Valim
    José Valim

    Yes, I understood that. But loading lib/active_support/* is not the right fix. :)

    March 18th, 2010 @ 04:47 PM

  5. Sebastian Martinez
    Sebastian Martinez

    Oh ok, sorry.
    Find attached new patch loading 'active_support/lib' to path.

    March 18th, 2010 @ 05:15 PM

  6. José Valim
    José Valim
    • Milestone cleared.
    • State changed from new to open

    Awesome, thanks! :D

    March 18th, 2010 @ 05:16 PM

  7. Santiago Pastorino
    Santiago Pastorino
    • State changed from open to new

    I was helping Sebastian with that, i think we should require abstract_unit to prevent this kind of troubles.
    Anyways this test ran standalone fails with:
    I'm going to take a look at this things too.

    ...FF...........................................F.F.............................. Finished in 111.80542 seconds.

    1) Failure: test ./callback_inheritance_test.rb(TestIsolated)

    [ts_isolated.rb:13:in `test ./callback_inheritance_test.rb'
     /var/lib/gems/1.8/gems/mocha-0.9.8/lib/mocha/integration/test_unit/ruby_version_186_and_above.rb:19:in `__send__'
     /var/lib/gems/1.8/gems/mocha-0.9.8/lib/mocha/integration/test_unit/ruby_version_186_and_above.rb:19:in `run']:
    

    /usr/bin/ruby1.8 -Ilib:test ./callback_inheritance_test.rb

    2) Failure: test ./callbacks_test.rb(TestIsolated)

    [ts_isolated.rb:13:in `test ./callbacks_test.rb'
     /var/lib/gems/1.8/gems/mocha-0.9.8/lib/mocha/integration/test_unit/ruby_version_186_and_above.rb:19:in `__send__'
     /var/lib/gems/1.8/gems/mocha-0.9.8/lib/mocha/integration/test_unit/ruby_version_186_and_above.rb:19:in `run']:
    

    /usr/bin/ruby1.8 -Ilib:test ./callbacks_test.rb

    3) Failure: test ./dependencies_test.rb(TestIsolated)

    [ts_isolated.rb:13:in `test ./dependencies_test.rb'
     /var/lib/gems/1.8/gems/mocha-0.9.8/lib/mocha/integration/test_unit/ruby_version_186_and_above.rb:19:in `__send__'
     /var/lib/gems/1.8/gems/mocha-0.9.8/lib/mocha/integration/test_unit/ruby_version_186_and_above.rb:19:in `run']:
    

    /usr/bin/ruby1.8 -Ilib:test ./dependencies_test.rb Loaded suite ./dependencies_test
    Started
    .............................................................F Finished in 0.21817 seconds.

    1) Failure: test_warnings_should_be_enabled_on_first_load(DependenciesTest)

    [./dependencies_test.rb:101:in `test_warnings_should_be_enabled_on_first_load'
     ./dependencies_test.rb:30:in `with_loading'
     ./dependencies_test.rb:87:in `test_warnings_should_be_enabled_on_first_load'
     /var/lib/gems/1.8/gems/mocha-0.9.8/lib/mocha/integration/test_unit/ruby_version_186_and_above.rb:19:in `__send__'
     /var/lib/gems/1.8/gems/mocha-0.9.8/lib/mocha/integration/test_unit/ruby_version_186_and_above.rb:19:in `run']:
    

    is not true.

    62 tests, 208 assertions, 1 failures, 0 errors

    4) Failure: test ./flush_cache_on_private_memoization_test.rb(TestIsolated)

    [ts_isolated.rb:13:in `test ./flush_cache_on_private_memoization_test.rb'
     /var/lib/gems/1.8/gems/mocha-0.9.8/lib/mocha/integration/test_unit/ruby_version_186_and_above.rb:19:in `__send__'
     /var/lib/gems/1.8/gems/mocha-0.9.8/lib/mocha/integration/test_unit/ruby_version_186_and_above.rb:19:in `run']:
    

    /usr/bin/ruby1.8 -Ilib:test ./flush_cache_on_private_memoization_test.rb

    March 18th, 2010 @ 07:44 PM

  8. Santiago Pastorino
    Santiago Pastorino
    • State changed from new to open

    March 18th, 2010 @ 07:44 PM

  9. Santiago Pastorino
    Santiago Pastorino

    Some tests ts_isolated runs should require abstract_unit too.
    Here's the right patch.

    March 18th, 2010 @ 07:59 PM

  10. Santiago Pastorino
    Santiago Pastorino

    Running dependencies_test standalone fails so we added another commit to the patch to make it green.
    Apply this one.

    March 18th, 2010 @ 08:17 PM

  11. Santiago Pastorino
  12. Santiago Pastorino
    Santiago Pastorino

    Ohh sorry the previous patches broke test if you ran with rake test:isolated. I've deleted all my wrong uploaded patches. Now everything is working fine.

    March 18th, 2010 @ 10:10 PM

  13. Repository
    Repository
    • State changed from open to committed

    (from [1e2caa5d52b9f367a1d7dc51d063a7ab1444b712]) Added missing requires abstract_unit and activesupport to the loadpath of ts_isolated [#4215 [PATCH] ActiveSupport ts_isolated test not running state:committed]

    Signed-off-by: wycats wycats@gmail.com
    http://github.com/rails/rails/commit/1e2caa5d52b9f367a1d7dc51d063a7...

    March 19th, 2010 @ 12:50 AM

  14. Repository
  15. Jeremy Kemper