-
Notifications
You must be signed in to change notification settings - Fork 78
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Making conditional a platform check because it relies on Ruby classes that don't exist in newer versions of Ruby.
- Loading branch information
Showing
1 changed file
with
8 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2a884de
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I notice there's no test coverage here. Does the
RUBY_VERSION
check say "it starts with either 1, 2, or 3, followed by a dot"?If so, are you sure that's what you meant to check? Or is there an OS X Ruby version in existence whose version starts with 4?
2a884de
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Whoops! My headspace must have been over in Gherkin land (which released 4.0 some months back). That should be a check for Ruby <2.4 (/^1|2.[123]/ or something like that).
There's no testing for it due to not having anything with OSX to test on. I develop on a Windows/Unix dual boot and the CI build on TravisCI is Unix (I think).
Good catch! Feel free to patch and PR. Otherwise I'll get on it in a day or so.
2a884de
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rather than just send a narrow patch, for a somewhat vital infrastructure library like this, it might be better for the community to add Travis matrix coverage on Mac.
I could take a stab at that -- first getting a test which fails in a Travis build, then the fix -- if you agree with the value and don't get to it before me?
2a884de
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For some reason, I was thinking that Travis didn't offer an OSX environment but, now that you mention it, it looks like it does (now if only they'd offer a Windows environment as well...). That being the case, yes, I agree that adding OSX to the CI build is the thing to do.