function clearAllCollections() {
  Prompts.remove({});
  Submissions.remove({});
}

Meteor.methods({

  clearAllCollections: clearAllCollections,

  setupFixtures: function() {
    clearAllCollections();

    var id = Prompts.insert("test prompt");
    Submissions.insert({
      promptId: id,
      response: 'test response'
    });
  }
});

function clearAllCollections() {
  Prompts.remove({});
  Submissions.remove({});
}

Meteor.methods({

  clearAllCollections: clearAllCollections,

  setupFixtures: function() {
    clearAllCollections();

    var id = Prompts.create("test prompt");
    Submissions.insert({
      responses: [{
        promptId: id,
        response: 'test response'
      }]
    });
  }
});
Fix JSON formation in test helper methods
Berke+Michael: Fix JSON formation in test helper methods
