aboutsummaryrefslogtreecommitdiffstats
path: root/vnfmarket/src/main/webapp/vnfmarket/node_modules/karma-spec-reporter/test/index.spec.js
diff options
context:
space:
mode:
authorseshukm <seshu.kumar.m@huawei.com>2017-04-10 15:52:12 +0530
committerseshukm <seshu.kumar.m@huawei.com>2017-04-10 15:52:12 +0530
commit84b3a1c939dc2baf22f9f5e30029b263c1512ade (patch)
tree131f2c17ad61078f95425eab1e349b96d0245d36 /vnfmarket/src/main/webapp/vnfmarket/node_modules/karma-spec-reporter/test/index.spec.js
parentef9cd2561e325c82d4d1fcb03fef4582a53d7839 (diff)
Integration of VNFMarket to Main GUI
IssueId : CLIENT-189 Change-Id: I37f49f6447ba2d5fb57779754117549eb315f0b5 Signed-off-by: seshukm <seshu.kumar.m@huawei.com>
Diffstat (limited to 'vnfmarket/src/main/webapp/vnfmarket/node_modules/karma-spec-reporter/test/index.spec.js')
-rw-r--r--vnfmarket/src/main/webapp/vnfmarket/node_modules/karma-spec-reporter/test/index.spec.js40
1 files changed, 40 insertions, 0 deletions
diff --git a/vnfmarket/src/main/webapp/vnfmarket/node_modules/karma-spec-reporter/test/index.spec.js b/vnfmarket/src/main/webapp/vnfmarket/node_modules/karma-spec-reporter/test/index.spec.js
new file mode 100644
index 00000000..60e78c7f
--- /dev/null
+++ b/vnfmarket/src/main/webapp/vnfmarket/node_modules/karma-spec-reporter/test/index.spec.js
@@ -0,0 +1,40 @@
+'use strict';
+var should = require('chai').should();
+var SpecReporter = require('../index')['reporter:spec'];
+var formatError = function (a, b) {
+ return a + b;
+};
+var noop = function noop() {};
+var baseReporterDecorator = function (context) {
+ context.renderBrowser = noop;
+ context.writeCommonMsg = noop;
+ context.write = noop;
+};
+var config = {};
+describe('SpecReporter', function () {
+ describe('when initializing', function () {
+ describe('and colors are not defined', function () {
+ var newSpecReporter;
+
+ beforeEach(function () {
+ newSpecReporter = new SpecReporter[1](baseReporterDecorator, formatError, config);
+ });
+
+ it('SpecReporter should be defined appropriately', function () {
+ SpecReporter[0].should.equal('type');
+ newSpecReporter.should.be.a('object');
+ });
+
+ it('should set USE_COLORS to false', function () {
+ newSpecReporter.USE_COLORS.should.equal(false);
+ });
+
+ it('should reset currentSuite array on run complete', function () {
+ newSpecReporter.currentSuite.push('suite name');
+ newSpecReporter.onRunComplete([]);
+
+ newSpecReporter.currentSuite.length.should.equal(0);
+ });
+ });
+ });
+});