Skip to content

Commit

Permalink
Трудности с пробросом переменных #32
Browse files Browse the repository at this point in the history
  • Loading branch information
xlinur committed Jun 4, 2021
1 parent 93c7d0a commit 8ce6907
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
1 change: 1 addition & 0 deletions modules/mocha-testrail-ui/eslint.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@ module.exports = {
testcase: true,
step: true,
expected: true,
store: true,
},
}
5 changes: 5 additions & 0 deletions modules/mocha-testrail-ui/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
import * as Mocha from 'mocha'

interface Store {
[key: string]: any;
}

declare global {
const testcase: Mocha.SuiteFunction
const step: Mocha.TestFunction
const expected: Mocha.TestFunction
const store: Store;
}
3 changes: 2 additions & 1 deletion modules/mocha-testrail-ui/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@ module.exports = function bddInterface(rootSuite) {
context.beforeEach = common.beforeEach
context.afterEach = common.afterEach
context.run = mocha.options.delay && common.runWithSuite(rootSuite)

// store for share variables
context.store = {};
/**
* testcase
*/
Expand Down

0 comments on commit 8ce6907

Please sign in to comment.