Permalink
Browse files

fixing test to work with mongo 2.4 by having it not drop system.js

  • Loading branch information...
1 parent e019aac commit 24490fe551cfc557bc2ef46aaf3bb38ec90eef18 @rdingwell rdingwell committed Apr 23, 2013
Showing with 3 additions and 2 deletions.
  1. +1 −1 Gemfile.lock
  2. +2 −1 test/test_helper.rb
View
2 Gemfile.lock
@@ -1,7 +1,7 @@
PATH
remote: .
specs:
- quality-measure-engine (2.3.0)
+ quality-measure-engine (2.4.0)
delayed_job_mongoid (~> 2.0.0)
mongoid (~> 3.0)
moped (~> 1.4.2)
View
3 test/test_helper.rb
@@ -11,7 +11,8 @@
class MiniTest::Unit::TestCase
def load_system_js
- Mongoid.default_session['system.js'].drop
+
+ Mongoid.default_session['system.js'].where({}).remove
Dir.glob(File.join(File.dirname(__FILE__), 'fixtures', "library_functions", '*.js')).each do |json_fixture_file|
name = File.basename(json_fixture_file,".*")
fn = "function () {\n #{File.read(json_fixture_file)} \n }"

0 comments on commit 24490fe

Please sign in to comment.