Skip to content

Get coverage up to 100% on our source.#111

Merged
theengineear merged 1 commit into
mainfrom
improve-coverage
May 3, 2026
Merged

Get coverage up to 100% on our source.#111
theengineear merged 1 commit into
mainfrom
improve-coverage

Conversation

@theengineear

Copy link
Copy Markdown
Collaborator

Just a PR dedicated to bumping our coverage goals. There are a handful of things that are genuinely hard to test (bail, for example) and we leave those pragma’d for now.

Just a PR dedicated to bumping our coverage goals. There are a handful
of things that are genuinely hard to test (bail, for example) and we
leave those pragma’d for now.
Comment thread x-test-reporter.css.js
color: var(--not-ok);
text-decoration: underline;
}

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While looking at coverage, I noticed we didn’t fully delete the “failures” stuff that moved to x-test-cli.

Comment thread x-test.config.js
'./x-test-reporter.css.js': { lines: 100 },
'./x-test-root.js': { lines: 100 },
'./x-test-tap.js': { lines: 100 },
'./x-test.js': { lines: 100 },

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

Comment thread test/shared.js
* @param {RegExp} error
* @param {string} [message]
*/
export function assertThrows(fn, error, message) {

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We will likely add this and friends to assert.*. I needed this for testing here and figured I might as well start thinking about what a reasonable subset of node:assert would look like here. In this case, we just accept a message pattern (versus the full type union node:assert accepts). I sort of think that would be enough for us here. The rest of the actual node:assert interface for assert.throws is… complicated — perhaps overly so.

@theengineear theengineear merged commit 63024cf into main May 3, 2026
1 check passed
@theengineear theengineear deleted the improve-coverage branch May 3, 2026 21:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant