I have a package (yeputons/meteor-smart-publish) which uses observeChanges
a lot, and I want to add a test (I use TinyTest right now) which allows me to ensure that all such observers are terminated in the end and no handle.stop()
was skipped.
The straightforward way is: add the 'Facts' package (which is Meteor-internal), subscribe to 'meteor_facts' and check for observe-handles
property of item with _id="mongo-livedata"
, which is not very safe because it's all undocumented and can be modified in any way in the future.
Is there any more documented way of checking such things?