codeceptjs 3.7.0-beta.17 → 3.7.0-beta.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -131,19 +131,20 @@ module.exports = async function (options) {
131
131
  if (Object.keys(helpers).length) {
132
132
  const suite = container.mocha().suite
133
133
  const test = createTest('test', () => {})
134
- try {
135
- for (const helper of Object.values(helpers)) {
134
+ checks.setup = true
135
+ for (const helper of Object.values(helpers)) {
136
+ try {
136
137
  if (helper._beforeSuite) await helper._beforeSuite(suite)
137
138
  if (helper._before) await helper._before(test)
138
139
  if (helper._passed) await helper._passed(test)
139
140
  if (helper._after) await helper._after(test)
140
141
  if (helper._finishTest) await helper._finishTest(suite)
141
- if (helper._afterSuite) await helper._afterSuite(suite)
142
+ if (helper._afterSuite) await helper._afterSuite(suite)
143
+ } catch (err) {
144
+ err.message = `${helper.constructor.name} helper: ${err.message}`
145
+ if (checks.setup) err.message = `${err.message}\n\n${checks.setup?.message}`
146
+ checks.setup = err
142
147
  }
143
- checks.setup = true
144
- } catch (err) {
145
- err.message = `${helper.constructor.name} helper failed: ${err.message}`
146
- checks.setup = err
147
148
  }
148
149
  }
149
150
 
@@ -6,7 +6,7 @@ const defaultConfig = {
6
6
 
7
7
  module.exports = function (config) {
8
8
  config = Object.assign(defaultConfig, config)
9
- console.log(`Deprecation Warning: 'retryTo' has been moved to the 'codeceptjs/effects' module`)
9
+ console.log(`Deprecation Warning: 'retryTo' has been moved to the 'codeceptjs/effects' module. Disable retryTo plugin to remove this warning.`)
10
10
 
11
11
  if (config.registerGlobal) {
12
12
  global.retryTo = retryTo
@@ -6,7 +6,7 @@ const defaultConfig = {
6
6
 
7
7
  module.exports = function (config) {
8
8
  config = Object.assign(defaultConfig, config)
9
- console.log(`Deprecation Warning: 'tryTo' has been moved to the 'codeceptjs/effects' module`)
9
+ console.log(`Deprecation Warning: 'tryTo' has been moved to the 'codeceptjs/effects' module. Disable tryTo plugin to remove this warning.`)
10
10
 
11
11
  if (config.registerGlobal) {
12
12
  global.tryTo = tryTo
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codeceptjs",
3
- "version": "3.7.0-beta.17",
3
+ "version": "3.7.0-beta.18",
4
4
  "description": "Supercharged End 2 End Testing Framework for NodeJS",
5
5
  "keywords": [
6
6
  "acceptance",