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

Cucumber expressions 600 match integers as floats #605

Merged

Conversation

aslakhellesoy
Copy link
Contributor

Summary

Match 0 with a {float} parameter

Details

Change the float regexp to make the decimal part optional.

Motivation and Context

See #600.

How Has This Been Tested?

With new tests

Types of changes

  • Bug fix (non-breaking change which fixes an issue).
  • New feature (non-breaking change which adds functionality).
  • Breaking change (fix or feature that would cause existing functionality to not work as expected).

Checklist:

  • I've added tests for my code.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.

Copy link
Contributor

@luke-hill luke-hill left a comment

Choose a reason for hiding this comment

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

Not that important, but it'd be slightly smaller if we used -?\d*[.,]?\d+ - Ran it through a bunch of expressions online and it's the same.

@aslakhellesoy aslakhellesoy merged commit 7420121 into master Jul 1, 2019
@luke-hill luke-hill deleted the cucumber-expressions-600-match-integers-as-floats branch July 30, 2019 07:07
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.

2 participants