fix: use regex instead of string literal for /yr text match in TotalAfterTrialRow test#173
Draft
fix: use regex instead of string literal for /yr text match in TotalAfterTrialRow test#173
/yr text match in TotalAfterTrialRow test#173Conversation
Agent-Logs-Url: https://github.com/edx/frontend-app-enterprise-checkout/sessions/03e490ef-1022-478b-aa89-e610bf76f440 Co-authored-by: rkumarsingh-sonata-crypto <265776069+rkumarsingh-sonata-crypto@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix validateText call in TotalAfterTrialRow test
fix: use regex instead of string literal for Apr 10, 2026
/yr text match in TotalAfterTrialRow test
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
validateText('-/yr')was passing a plain string containing an unescaped/, where a regex is required to correctly match the literal/yrsubstring in the rendered output.Change
TotalAfterTrialRow.test.tsxline 23: Replace string'-/yr'with regex/-\/yr/, consistent with the pattern already used on line 31.Original prompt
This pull request was created from Copilot chat.