Skip to content

test: improved test robustness#320

Merged
UlisesGascon merged 1 commit intoexpressjs:masterfrom
Alex-GF:master
Oct 7, 2024
Merged

test: improved test robustness#320
UlisesGascon merged 1 commit intoexpressjs:masterfrom
Alex-GF:master

Conversation

@Alex-GF
Copy link
Copy Markdown
Contributor

@Alex-GF Alex-GF commented May 6, 2024

This Pull Request addresses an issue regarding the testing of the handling and generation of Access-Control-Allow-Headers header. Through the application of mutation testing, I have identified a potential mutation in the configuration logic that was not covered by the existing tests (issue fully explain in this threat).

Proposed Change

To mitigate this, I suggest changing the assertion method from assert.equal to assert.strictEqual in the test/test.js file, specifically at line 444. This alteration would ensure that the tests verify not only the value but also the exact type of the header content, thereby preventing potential type coercion issues.

Additional Information

This Pull Request has been created following the directions of @UlisesGascon.

Looking forward to your feedback and approval.

Thank you for considering this enhancement.

Best regards.


Edited by @UlisesGascon

closes #319

Copy link
Copy Markdown
Member

@UlisesGascon UlisesGascon left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks for preparing the PR @Alex-GF ❤️

@UlisesGascon UlisesGascon merged commit 53312a5 into expressjs:master Oct 7, 2024
This was referenced Jan 19, 2026
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.

Improve testing robustness

2 participants