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

#3258 - Bug in the Error creation of CAS Supplier #4071

Merged
merged 2 commits into from
Dec 11, 2024

Conversation

guru-aot
Copy link
Collaborator

Trim function was called after the split, it should have been called before it.
image

@guru-aot guru-aot self-assigned this Dec 11, 2024
@guru-aot guru-aot added the Bug Something isn't working label Dec 11, 2024
Copy link

E2E SIMS API Coverage Report

Totals Coverage
Statements: 67.41% ( 5927 / 8792 )
Methods: 65.09% ( 729 / 1120 )
Lines: 71.35% ( 4652 / 6520 )
Branches: 47.4% ( 546 / 1152 )

Copy link
Collaborator

@andrepestana-aot andrepestana-aot left a comment

Choose a reason for hiding this comment

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

Looks good. Weird how it was not shown as an error before.

Copy link
Collaborator

@dheepak-aot dheepak-aot left a comment

Choose a reason for hiding this comment

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

Looks good.

@guru-aot guru-aot added this pull request to the merge queue Dec 11, 2024
Merged via the queue into main with commit 7a58eb3 Dec 11, 2024
15 of 16 checks passed
Copy link

Backend Unit Tests Coverage Report

Totals Coverage
Statements: 21.93% ( 3764 / 17162 )
Methods: 10.06% ( 215 / 2138 )
Lines: 25.28% ( 3269 / 12931 )
Branches: 13.38% ( 280 / 2093 )

@guru-aot guru-aot deleted the feature/#3258_CAS_Supplier_Errors_Bug branch December 11, 2024 19:53
Copy link

E2E Workflow Workers Coverage Report

Totals Coverage
Statements: 65.43% ( 583 / 891 )
Methods: 59.26% ( 64 / 108 )
Lines: 68.54% ( 464 / 677 )
Branches: 51.89% ( 55 / 106 )

Copy link

E2E Queue Consumers Coverage Report

Totals Coverage
Statements: 84.94% ( 1342 / 1580 )
Methods: 83.33% ( 135 / 162 )
Lines: 86.45% ( 1129 / 1306 )
Branches: 69.64% ( 78 / 112 )

throw new CustomNamedError(
"CAS Bad Request Errors",
CAS_BAD_REQUEST,
casKnownErrors.split(" | ").trim(),
casKnownErrors.trim().split(" | "),
Copy link
Collaborator

Choose a reason for hiding this comment

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

To be clear, that was not what I meant when I said to trim().

Copy link
Collaborator

Choose a reason for hiding this comment

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

The string "Error 1 | Error 2" should be splitter by "|".
Then the results will be "Erro 1 " and " Error 2", those should have the trim() applied.
I also mentioned to have one unit test about it before the ticket was delivered.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants