Skip to content

Commit

Permalink
Core: Rename internal parentSuite variable to parentReport
Browse files Browse the repository at this point in the history
"module" and "suite" are mostly interchangable terms. "module" is
the object created by createModule(). Let's use "report" for the
SuiteReport object.
  • Loading branch information
Krinkle committed Jul 27, 2024
1 parent a7403bf commit 1058881
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core/module.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ function isParentModuleInQueue () {

function createModule (name, testEnvironment, modifiers) {
const parentModule = moduleStack.length ? moduleStack.slice(-1)[0] : null;
const parentReport = parentModule ? parentModule.suiteReport : runSuite;
const moduleName = parentModule !== null ? [parentModule.name, name].join(' > ') : name;
const parentSuite = parentModule ? parentModule.suiteReport : runSuite;

const skip = (parentModule !== null && parentModule.skip) || modifiers.skip;
const todo = (parentModule !== null && parentModule.todo) || modifiers.todo;
Expand All @@ -42,7 +42,7 @@ function createModule (name, testEnvironment, modifiers) {
testsRun: 0,
testsIgnored: 0,
childModules: [],
suiteReport: new SuiteReport(name, parentSuite),
suiteReport: new SuiteReport(name, parentReport),

// Initialised by test.js when the module start executing,
// i.e. before the first test in this module (or a child).
Expand Down

0 comments on commit 1058881

Please sign in to comment.