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

Clean up remaining post-extraction clutter #47

Merged
merged 15 commits into from
Mar 3, 2016
Merged

Conversation

craiglittle
Copy link
Collaborator

This gem was originally extracted from an internal project and continued to carry along some baggage from that time that no longer made sense in the context of a standalone library. This should mostly finish up the work to tidy up the remnants of that cruft as well as try out a couple more experimental ideas, such as being more aggressive about hiding access to constants meant for internal use.

Check out the individual commits for a more detailed breakdown of the work.

@alex-stone @joshlam

@ghost
Copy link

ghost commented Mar 1, 2016

👍

There's no longer any need to have a separate class to house this simple
logic.
This method isn't used anywhere within the project and shouldn't be
considered part of the public API.
In addition, define a public interface using class methods.
Since `Forwardable` is adding class methods and `Comparable is adding
instance methods.
I swear this is the last time I'm going to tweak this.

The primary reasoning here is that defining `<=>` on `Interval` will
make the sorting that happens during configuration time slightly
cleaner. At that point, there's no reason not to convert over `Holiday`
and `TimeSegment` too, and be done with it once and for all.
This might come back in the future if cross-day configuration is
explicitly supported.
I'm seeing the following the warning pop up occasionally when the build
runs on Travis:
```
/home/travis/build/zendesk/biz/lib/biz/configuration.rb:7: warning: possible reference to past scope - raw
```

This should take care of it.
This silences the following deprecation warning which appeared when
running the `benchmark/speed` script:
```
DEPRECATION WARNING: `Time.workday?(time)` is deprecated. Please use `time.workday?`.
```
These specs don't add much value and can confuse people about their
purpose.
@craiglittle
Copy link
Collaborator Author

@joshlam 💇

@craiglittle
Copy link
Collaborator Author

:shipit:

craiglittle added a commit that referenced this pull request Mar 3, 2016
Clean up remaining post-extraction clutter
@craiglittle craiglittle merged commit bb1cd3d into master Mar 3, 2016
@craiglittle craiglittle deleted the craig/slim-methods branch March 3, 2016 18:13
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.

1 participant