Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: add tests for runner coverage with different stdout column widths #54494

Merged
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
52 changes: 52 additions & 0 deletions test/fixtures/test-runner/coverage-snap/a.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
'use strict';
// Here we can't import common module as the coverage will be different based on the system

// Empty functions that don't do anything
function doNothing1() {
// Not implemented
}

function doNothing2() {
// No logic here
}

function unusedFunction1() {
// Intentionally left empty
}

function unusedFunction2() {
// Another empty function
}

// Unused variables
const unusedVariable1 = 'This is never used';
const unusedVariable2 = 42;
let unusedVariable3;

// Empty class with no methods
class UnusedClass {
constructor() {
// Constructor does nothing
}
}

// Empty object literal
const emptyObject = {};

// Empty array
const emptyArray = [];

// Function with parameters but no body
function doNothingWithParams(param1, param2) {
// No implementation
}

// Function that returns nothing
function returnsNothing() {
// No return statement
}

// Another unused function
function unusedFunction3() {
// More empty code
}
11 changes: 11 additions & 0 deletions test/fixtures/test-runner/coverage-snap/b.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
'use strict';
// Here we can't import common module as the coverage will be different based on the system

// Empty functions that don't do anything
function doNothing1() {
// Not implemented
}

function doNothing2() {
// No logic here
}
Loading
Loading