From 33d3a7421f9cab15bb8b59559bdf3395f4ef5afe Mon Sep 17 00:00:00 2001 From: "Christopher C. Wells" Date: Mon, 4 Dec 2023 20:59:01 -0800 Subject: [PATCH] Remove tests relying on PHP math expressions --- tests/Unit/Support/NumberTest.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/Unit/Support/NumberTest.php b/tests/Unit/Support/NumberTest.php index c57792e..3c84d1f 100644 --- a/tests/Unit/Support/NumberTest.php +++ b/tests/Unit/Support/NumberTest.php @@ -48,8 +48,8 @@ public function testFractionStringFromFloat(string $expectedString, float $float */ public function decimalStringFloatsProvider(): array { return [ - ['0.0', 0.0], ['0.125', 1/8], ['0.25', 1/4], ['0.5', 1/2], - ['0.75', 3/4], ['1.0', 1.0], ['1.25', 1.25], ['1.5', 1.5], + ['0.0', 0.0], ['0.125', 0.125], ['0.25', 0.25], ['0.5', 0.5], + ['0.75', 0.75], ['1.0', 1.0], ['1.25', 1.25], ['1.5', 1.5], ['2.5', 2.5], ['2.75', 2.75], ]; } @@ -62,9 +62,9 @@ public function decimalStringFloatsProvider(): array { */ public function fractionStringFloatsProvider(): array { return [ - ['0', 0.0], ['1/8', 1/8], ['1/4', 1/4], ['1/3', 1/3], ['1/2', 1/2], - ['2/3', 2/3], ['3/4', 3/4], ['1', 1.0], ['1 1/4', 1.25], ['1 1/3', 1 + 1/3], - ['1 1/2', 1.5], ['1 2/3', 1 + 2/3], ['2 1/2', 2.5], ['2 3/4', 2.75], + ['0', 0.0], ['1/8', 0.125], ['1/4', 0.25], ['1/2', 0.5], + ['3/4', 0.75], ['1', 1.0], ['1 1/4', 1.25], + ['1 1/2', 1.5], ['2 1/2', 2.5], ['2 3/4', 2.75], ]; } }