Skip to content
This repository has been archived by the owner on Jun 15, 2019. It is now read-only.

Commit

Permalink
Added test coverage.
Browse files Browse the repository at this point in the history
  • Loading branch information
jamestalmage committed Dec 14, 2014
1 parent f740119 commit f184b59
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
5 changes: 4 additions & 1 deletion .gitignore
@@ -1,2 +1,5 @@
node_modules/
.idea/
.idea/
coverage/
JasmineAdapter-1.1.2.js
jasmine-1.1.0.js
2 changes: 1 addition & 1 deletion gulpfile.js
Expand Up @@ -22,7 +22,7 @@ function coverageTask(cb){
.pipe(istanbul.hookRequire()) // Force `require` to return covered files
.on('error', logMochaError)
.on('finish', function () {
gulp.src(['tests/*.js'])
gulp.src(['test/*.js'])
.pipe(mocha(mochaOpts))
.pipe(istanbul.writeReports()) // Creating the reports after tests runned
.on('end', cb || function(){});
Expand Down
1 change: 0 additions & 1 deletion src/cell.js
Expand Up @@ -37,7 +37,6 @@ Cell.prototype.setOptions = function(options){
* @param y - The row this cell is in (with row 0 being at the top).
*/
Cell.prototype.init = function(tableOptions, x, y){
this.options = this.options || {};
this.options.style = this.options.style || {};
if(this.options.chars){
this.chars = _.extend({},tableOptions.chars,this.options.chars);
Expand Down
3 changes: 2 additions & 1 deletion test/cell-test.js
Expand Up @@ -622,7 +622,8 @@ describe('Cell',function(){

describe("NoOp",function(){
it('has an init function',function(){
expect(new NoOpCell()).to.respondTo('init');
expect(new NoOpCell()).to.respondTo('init');
new NoOpCell().init(); // nothing happens.
});

it('draw returns an empty string',function(){
Expand Down

0 comments on commit f184b59

Please sign in to comment.