Meteor methods returning data from dev DB in tests


#1

I am attempting to run a jasmine-server-integration test, I have a snippet which empties out the test DB.

I tested that this is working by doing:

		posts = Posts.find({}).fetch()
		console.log "Posts: ", posts

It returns: Posts: []

As expected. All good so far.

However when I call a method via Meteor.call which returns certain data from the database, it’s returning Posts that exist in the dev database.

Why are Meteor methods not running off of the test db? Is there any way to fix this? Thanks


#2

This seems like a pretty serious bug in Meteor, anyone have any thoughts? I’m not sure how to even go about debugging this. Just cloned the meteor core code, going to try and poke around there…