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

In Decimal class float method was contributed #608

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

nardnana28
Copy link

No description provided.

Copy link

linux-foundation-easycla bot commented May 8, 2024

CLA Signed

The committers listed above are authorized under a signed CLA.

Comment on lines 15 to 21
{-| Test: Decimal/fromFloat
expected = 1.2
-}
decimalFromFloatTest1 : TestContext -> Decimal
decimalFromFloatTest1 ctx =
test ctx
(Decimal.fromFloat 1.2)
Copy link
Contributor

Choose a reason for hiding this comment

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

Not sure if we need decimalFromFloatTest1.

decimalFromFloatTest looks to do the exact same thing with the exact same function -- fromFloat. import Morphir.SDK.Decimal as Decimal exposing (..) exposes fromFloat (and other Decimal functions) so that we could call it directly.

Copy link
Author

Choose a reason for hiding this comment

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

Ok, removed the unnecessary changes.

@@ -403,6 +403,7 @@ object EvaluatorMDMTests extends MorphirBaseSpec {
suite("Decimal Tests")(
suite("conversion")(
testEvaluation("fromFloat")("decimalTests", "decimalFromFloatTest")(Data.Decimal(1.2)),
testEvaluation("fromFloat")("decimalTests", "decimalFromFloatTest1")(Data.Decimal(1.2)),
Copy link
Contributor

Choose a reason for hiding this comment

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

No addition is necessary here?

Copy link
Author

Choose a reason for hiding this comment

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

Agree, Removed the line.

@nardnana28 nardnana28 requested a review from bensanchin May 9, 2024 14:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants