Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion docs/hooks.md
Original file line number Diff line number Diff line change
Expand Up @@ -467,7 +467,10 @@ codecept.initGlobals(__dirname);
Container.create(config, opts);

// initialize listeners
codecept.bootstrap();
codecept.runHooks();

// run bootstrap function from config
codecept.runBootstrap();

// load tests
codecept.loadTests('*_test.js');
Expand Down
4 changes: 2 additions & 2 deletions lib/command/definitions.js
Original file line number Diff line number Diff line change
Expand Up @@ -206,9 +206,9 @@ module.exports = function (genPath, options) {

function addAllMethodsInObject(supportObj, actions, methods, translations) {
for (const action of methodsOfObject(supportObj)) {
let fn = supportObj[action];
const fn = supportObj[action];
if (!fn.name) {
Object.defineProperty(fn, "name", {value: action});
Object.defineProperty(fn, 'name', { value: action });
}
const actionAlias = translations ? translations.actionAliasFor(action) : action;
if (!actions[actionAlias]) {
Expand Down
2 changes: 1 addition & 1 deletion lib/parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ function getParams(fn) {
});
return params;
} catch (err) {
console.log('Error in ' + newFn.toString());
console.log(`Error in ${newFn.toString()}`);
console.error(err);
}
}
Expand Down
2 changes: 1 addition & 1 deletion lib/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ const isGenerator = module.exports.isGenerator = function (fn) {
};

const isFunction = module.exports.isFunction = function (fn) {
return typeof fn === 'function'
return typeof fn === 'function';
};

const isAsyncFunction = module.exports.isAsyncFunction = function (fn) {
Expand Down