1
我想用茉莉花节点测试的角度模块的角度,我的测试是设置为包括茉莉节点
var fs = require('fs'); var angular = require('../bower_components/angular/angular') var fsm = require('../filesystemModel'); describe("get files",function(){ it("should get files from the file system",function(){ console.log(fsm); }); });
不幸的是,这不加载的角度,因此,filesystemModel打破,因为角度未定义。我认为这是因为角正在寻找window
和document
,我不认为它是在茉莉花节点中提供的。
我知道node-webkit谈到使用chromedriver进行测试,但我试图与模块测试一致,其中一些可以在node-webkit之外使用,有些需要node-webkit。
有关使用node-webkit进行茉莉花节点测试的任何建议?或者使用业力进行节点测试是另一种选择。