Writing the API (workin in progress)
This commit is contained in:
@@ -23,9 +23,9 @@ describe('phantomasWrapper', function() {
|
||||
data.should.have.a.property('generator');
|
||||
data.generator.should.contain('phantomas');
|
||||
data.should.have.a.property('url').that.equals(url);
|
||||
data.should.have.a.property('metrics').that.is.an('object').not.empty;
|
||||
data.should.have.a.property('offenders').that.is.an('object').not.empty;
|
||||
data.offenders.should.have.a.property('javascriptExecutionTree').that.is.a('array').not.empty;
|
||||
data.should.have.a.property('metrics').that.is.an('object').not.empty();
|
||||
data.should.have.a.property('offenders').that.is.an('object').not.empty();
|
||||
data.offenders.should.have.a.property('javascriptExecutionTree').that.is.a('array').not.empty();
|
||||
|
||||
done();
|
||||
}).fail(function(err) {
|
||||
@@ -73,9 +73,9 @@ describe('phantomasWrapper', function() {
|
||||
data.should.have.a.property('generator');
|
||||
data.generator.should.contain('phantomas');
|
||||
data.should.have.a.property('url').that.equals(url);
|
||||
data.should.have.a.property('metrics').that.is.an('object').not.empty;
|
||||
data.should.have.a.property('offenders').that.is.an('object').not.empty;
|
||||
data.offenders.should.have.a.property('javascriptExecutionTree').that.is.a('array').not.empty;
|
||||
data.should.have.a.property('metrics').that.is.an('object').not.empty();
|
||||
data.should.have.a.property('offenders').that.is.an('object').not.empty();
|
||||
data.offenders.should.have.a.property('javascriptExecutionTree').that.is.a('array').not.empty();
|
||||
|
||||
done();
|
||||
}).fail(function(err) {
|
||||
|
||||
@@ -34,7 +34,7 @@ describe('yellowlabtools', function() {
|
||||
this.timeout(15000);
|
||||
|
||||
// Check if console.log is called
|
||||
sinon.spy(console, 'log')
|
||||
sinon.spy(console, 'log');
|
||||
|
||||
var url = 'http://localhost:8388/simple-page.html';
|
||||
|
||||
@@ -75,6 +75,7 @@ describe('yellowlabtools', function() {
|
||||
"offenders": ["body > h1[1]"]
|
||||
});
|
||||
|
||||
/*jshint expr: true*/
|
||||
console.log.should.not.have.been.called;
|
||||
|
||||
done();
|
||||
|
||||
Reference in New Issue
Block a user