From 4e6fa2ee558d3e982258178649ae5ad844b05d02 Mon Sep 17 00:00:00 2001 From: FitseTLT Date: Mon, 23 Dec 2024 17:15:34 +0300 Subject: [PATCH] added test --- tests/unit/PolicyDistanceRatesUtilsTest.ts | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 tests/unit/PolicyDistanceRatesUtilsTest.ts diff --git a/tests/unit/PolicyDistanceRatesUtilsTest.ts b/tests/unit/PolicyDistanceRatesUtilsTest.ts new file mode 100644 index 000000000000..f3761d509baa --- /dev/null +++ b/tests/unit/PolicyDistanceRatesUtilsTest.ts @@ -0,0 +1,13 @@ +import {validateTaxClaimableValue} from '@libs/PolicyDistanceRatesUtils'; + +describe('PolicyDistanceRatesUtils', () => { + describe('validateTaxClaimableValue', () => { + it('should return false when taxClaimableValue is equal to rate', () => { + // Given a tax claimable value inserted for a distance rate + // When the taxClaimableValue is equal to the distance rate + const validate = validateTaxClaimableValue({taxClaimableValue: '0.67'}, {rate: 67}); + // Then validateTaxClaimableValue will return an error. + expect(validate.taxClaimableValue).toBeDefined(); + }); + }); +});