[-]:feat/checkout little improves#1963
Merged
Merged
Conversation
xabg2
reviewed
May 21, 2026
| "apply": "Apply", | ||
| "taxes": "Taxes", | ||
| "annualBillingTemplate": "Annual plan, billed monthly at {{price}}{{currency}}/month for 12 months" | ||
| "annualBillingTemplate": "Annual plan, billed at {{currency}}{{priceNow}} for the first month, then renews at {{currency}}{{price}}/month" |
Contributor
There was a problem hiding this comment.
Update the text for all languages.
| expect(formatPrice(10.0000001)).toBe('10'); | ||
| }); | ||
|
|
||
| it('Handles floating point precision error (19.99 * 100 = 1998.999... in JS)', () => { |
Contributor
There was a problem hiding this comment.
and change it from "it" to "test".
the "it" tests are like: it('should do .... when doing ....')
the "test" tests are like: test('When doing .... then it does .....')
Deploying drive-web with
|
| Latest commit: |
86ef365
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://b84d18d4.drive-web.pages.dev |
| Branch Preview URL: | https://feat-fix-checkout.drive-web.pages.dev |
xabg2
reviewed
May 22, 2026
| describe('The price has more than 2 decimals', () => { | ||
| it('When the price has more than 2 decimals, then the function returns the price with 2 decimals (truncated with high precision, 10.456 -> 10.45 - 10.001 -> 10 - 1.999 -> 1.99)', () => { | ||
| expect(formatPrice(10.456)).toBe('10.45'); | ||
| it('When the price has more than 2 decimals, then the function returns the price rounded to 2 decimals (10.456 -> 10.46 - 10.001 -> 10 - 1.999 -> 2)', () => { |
xabg2
reviewed
May 29, 2026
| it('When the user has a price with 1 decimal, the function returns 2 decimals (100.5 -> 100.50)', () => { | ||
| expect(formatPrice(100.5)).toBe('100.50'); | ||
| }); | ||
| it('When the user has a price with 1 decimal, the function returns 2 decimals (100.5 -> 100.50)', () => { |
| it('When the user has a price with 2 decimals, the function returns 2 decimals (99.99 -> 99.99)', () => { | ||
| expect(formatPrice(99.99)).toBe('99.99'); | ||
| }); | ||
| it('When the user has a price with 2 decimals, the function returns 2 decimals (99.99 -> 99.99)', () => { |
|
larryrider
approved these changes
May 29, 2026
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.



Description
This PR aims to update pair of things on the checkout:
Related Issues
Related Pull Requests
Checklist
Testing Process
Checked on local that the checkout now shows as expected
Additional Notes