Comparing version 1.4.0 to 1.4.1
{ | ||
"name": "debugutil", | ||
"version": "1.4.0", | ||
"version": "1.4.1", | ||
"description": "Debug Utility Tool with Logging", | ||
@@ -28,4 +28,5 @@ "main": "src/debug.js", | ||
"eslint-plugin-react": "^6.9.0", | ||
"istanbul": "^0.4.5", | ||
"mocha": "^3.2.0" | ||
} | ||
} |
@@ -42,2 +42,6 @@ ## debugutil | ||
I have also included Unit Testing for this package. Unit Testing is provided using [chai](https://www.npmjs.com/package/chai), [supertest]https://www.npmjs.com/package/supertest() and [mocha](https://www.npmjs.com/package/mocha). | ||
To run Unit Test, run the following command in your CLI: | ||
```javascript | ||
mocha | ||
``` | ||
@@ -44,0 +48,0 @@ ## Code Coverage |
// Debug Utility Tool with Logging by Melony Smith | ||
/* eslint-env mocha */ | ||
const request = require('supertest'); | ||
@@ -9,5 +8,21 @@ const expect = require('chai'); | ||
describe('Debug', () => { | ||
it('Debug OK', () => { | ||
}); | ||
}); | ||
describe ('debugutil', () => { | ||
const logArray = [ | ||
{ | ||
testName: 'should log error', | ||
functionName: debug.debugSuccess, | ||
functionType: 'debug.debugSuccess', | ||
}, | ||
{ | ||
testName: 'should log success', | ||
functionName: debug.debugError, | ||
functionType: 'debug.debugError', | ||
}, | ||
] | ||
for (let i = 0; i < logArray.length; i++) { | ||
it (logArray[i].testName, (done) => { | ||
logArray[i].functionName('This is a '+ logArray[i].functionType + ' test') | ||
done() | ||
}) | ||
} | ||
}) |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
4726
51
69
7