"cc is not defined" when i run my tests

I’m running the JS flavor of cocos2d-x. Further, I’m writing my code in es6, and using a build step to compile down to es5. And my test runner is Ava.

When Ava gets around to running my application code, it encounters me using the “cc” global I’m using for the Cocos apis, and it doesn’t know what to do with that.

Any thoughts? Should I be importing “cc” explicitly? Should I be telling Ava about “cc” somehow?

Hi @chrispitzer,

"cc is not defined" : You need to include Cocos2d-JS framework.

Inside JS framework framework under CCBoot.js file cc is defined. You can create Lite Version of JS framework using below link.
http://www.cocos2d-x.org/filecenter/jsbuilder

Regards,
Gurudath