Meteor-Community-Packages / meteor-mocha

A Mocha test driver package for Meteor 1.3+. This package reports server AND client test results in the server console and can be used for running tests on a CI server or locally.
https://packosphere.com/meteortesting/mocha
MIT License
67 stars 40 forks source link

Tests failing when looking for BrowserPolicy.content #67

Closed etyp closed 6 years ago

etyp commented 6 years ago

We only use the browser-policy-framing package, which makes the check for Package['browser-policy-common'] pass, but since we don't use browser-policy-content we get the following error on test runs now:

W20180608-17:13:06.473(0)? (STDERR) TypeError: Cannot read property 'allowInlineStyles' of undefined
W20180608-17:13:06.473(0)? (STDERR)     at server.js (packages/meteortesting:mocha/server.js:13:25)

It happens because the check here assumes we're also using browser-policy-content though we're not. We didn't experience this before Meteor 1.7, which is odd.

It seems to me that this conditional should check for browser-policy-common AND browser-policy-content. Does that seem right?

SimonSimCity commented 6 years ago

@etyp does #68 solve this issue? If it does, please close this issue.