aboutsummaryrefslogtreecommitdiff
path: root/node_modules/mocha/lib/interfaces/common.js
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2017-05-27 17:36:13 +0200
committerFlorian Dold <florian.dold@gmail.com>2017-05-27 17:36:13 +0200
commit5f466137ad6ac596600e3ff53c9b786815398445 (patch)
treef914c221874f0b16bf3def7ac01d59d1a99a3b0b /node_modules/mocha/lib/interfaces/common.js
parentc9f5ac8e763eda19aa0564179300cfff76785435 (diff)
node_modules, clean up package.json
Diffstat (limited to 'node_modules/mocha/lib/interfaces/common.js')
-rw-r--r--node_modules/mocha/lib/interfaces/common.js85
1 files changed, 0 insertions, 85 deletions
diff --git a/node_modules/mocha/lib/interfaces/common.js b/node_modules/mocha/lib/interfaces/common.js
deleted file mode 100644
index db939085c..000000000
--- a/node_modules/mocha/lib/interfaces/common.js
+++ /dev/null
@@ -1,85 +0,0 @@
-'use strict';
-
-/**
- * Functions common to more than one interface.
- *
- * @param {Suite[]} suites
- * @param {Context} context
- * @return {Object} An object containing common functions.
- */
-module.exports = function(suites, context) {
- return {
- /**
- * This is only present if flag --delay is passed into Mocha. It triggers
- * root suite execution.
- *
- * @param {Suite} suite The root wuite.
- * @return {Function} A function which runs the root suite
- */
- runWithSuite: function runWithSuite(suite) {
- return function run() {
- suite.run();
- };
- },
-
- /**
- * Execute before running tests.
- *
- * @param {string} name
- * @param {Function} fn
- */
- before: function(name, fn) {
- suites[0].beforeAll(name, fn);
- },
-
- /**
- * Execute after running tests.
- *
- * @param {string} name
- * @param {Function} fn
- */
- after: function(name, fn) {
- suites[0].afterAll(name, fn);
- },
-
- /**
- * Execute before each test case.
- *
- * @param {string} name
- * @param {Function} fn
- */
- beforeEach: function(name, fn) {
- suites[0].beforeEach(name, fn);
- },
-
- /**
- * Execute after each test case.
- *
- * @param {string} name
- * @param {Function} fn
- */
- afterEach: function(name, fn) {
- suites[0].afterEach(name, fn);
- },
-
- test: {
- /**
- * Pending test case.
- *
- * @param {string} title
- */
- skip: function(title) {
- context.test(title);
- },
-
- /**
- * Number of retry attempts
- *
- * @param {number} n
- */
- retries: function(n) {
- context.retries(n);
- }
- }
- };
-};