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

.1 parsing #166

Merged
merged 3 commits into from Feb 14, 2020
Merged

.1 parsing #166

merged 3 commits into from Feb 14, 2020

Conversation

izulin
Copy link
Collaborator

@izulin izulin commented Feb 12, 2020

Context

parsing of .1 type decimals in formulas

How has this been tested?

unit test

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature or improvement (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Additional language file or change to the existing one (translations)

Related issue(s):

  1. Decimal parsing inconsistency #119

Checklist:

  • My code follows the code style of this project,
  • My change requires a change to the documentation,
  • I described the modification in the CHANGELOG.md file.

@izulin izulin linked an issue Feb 13, 2020 that may be closed by this pull request
This was referenced Feb 14, 2020
Copy link
Contributor

@wojciechczerniak wojciechczerniak left a comment

Choose a reason for hiding this comment

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

Works great 👍 It would be cool to extend the test with some more cases

const engine = HyperFormula.buildFromArray([
['.1', '=.1'],
['-.1', '=-.1']
])
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we add few more tests? To future proof our tests and be sure that decimal is parsed correctly within the functions and with operators:

      ['.1', '=.1'],
      ['-.1', '=-.1'],
      ['+.1', '=+.1'],
      ['+.1', '=+.1+.2'],
      ['=SUM(A1:A4, 0.3, .3)', '=SUM(B1:B4)'],
      ['.1.4', '=..1'],

Maybe you can add some more

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

sorry, didn't notice your comment here. I'll add it in some other commit.

@izulin izulin merged commit 0282a62 into master Feb 14, 2020
izulin added a commit that referenced this pull request Feb 14, 2020
This reverts commit 0282a62.
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.

Decimal parsing inconsistency
2 participants