Skip to content

Commit

Permalink
formatMoney() additional test
Browse files Browse the repository at this point in the history
  • Loading branch information
karczk-dnv committed Oct 5, 2022
1 parent b3ffd0f commit 22e85bd
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions __tests__/formatMoney.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ describe('formatMoney', () => {
});

test("using partial options", () => {
expect(formatMoney(1.53588, { }, "en")).toEqual("1.54");
expect(formatMoney(1.53588, { precision: 3 }, "en")).toEqual("1.536");
expect(formatMoney(1.53588, { currency: "USD" }, "en")).toEqual("$1.54");
expect(formatMoney(1.53588, { currency: "USD", currencyDisplay: "code" }, "en")).toEqual(`USD${IntlWhitespace}1.54`);
Expand Down

0 comments on commit 22e85bd

Please sign in to comment.