Fix development dependencies, so that specs can be run properly #112

Open
wants to merge 1 commit into from

3 participants

@wolframarnold

The gemspec was missing the proper development dependencies for the test suite to run, notably
Rails 2.3.x:
Sqlite3

The test suite is NOT Rails 3 compatible; test_helper.rb tries to require "initializer" online 20, which is not available in Rails 3.

@stffn
Owner

Well, I'm testing against Rails 3, so it does work.

I'm fully with you on improving the test infrastructure, though. The current architecture is still based on Rails 2, though. To test, I currently have an empty Rails 3 app, execute a bundle exec bash from there, switch into the decl_auth path and run rake. Not great, I agree. Thus, any improvements welcome. Should work in Rails 2 as well, though.

@dgm

Doesn't work with a bare rails 3.2 app.

@stffn
Owner

Strangely enough, it works for me for Rails 3.2.5:

rails new test_app
cd test_app
bundle exec bash
cd decl_auth_path
RAILS_ROOT=path_to_test_app rake
@dgm

I must have missed setting the rails root or something. but now, when I run the tests using that procedure (master branch, not my changes) I get a ton of errors: https://gist.github.com/1bb55e0e3c07190f6e76

@stffn
Owner

de590c5 should have fixed that. Do you see them, even with that commit?

@dgm

That's better, I'm down to:

 
test_usages_by_controllers(MaintenanceTest):
NoMethodError: undefined method `demodulize' for nil:NilClass
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment