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

Add Context#to_h #136

Merged
merged 3 commits into from
Mar 26, 2023
Merged

Add Context#to_h #136

merged 3 commits into from
Mar 26, 2023

Conversation

tmaier
Copy link
Contributor

@tmaier tmaier commented Mar 22, 2023

About the changes

Add a to_h method to Context.

Closes #135

Copy link
Member

@sighphyre sighphyre left a comment

Choose a reason for hiding this comment

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

Yeah, nice improvement, LGTM

@sighphyre
Copy link
Member

@tmaier Looks like there's a small bit of formatting Rubocop doesn't like, happy to merge once that's fixed

@coveralls
Copy link

coveralls commented Mar 23, 2023

Pull Request Test Coverage Report for Build 4524790842

  • 5 of 5 (100.0%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+4.2%) to 96.553%

Totals Coverage Status
Change from base Build 4234430778: 4.2%
Covered Lines: 2157
Relevant Lines: 2234

💛 - Coveralls

@rarruda
Copy link
Collaborator

rarruda commented Mar 23, 2023

Agree! This is definitely nice to have!

Should be ok to merge once rubocop is happy. 😊

Layout/TrailingWhitespace and Layout/SpaceBeforeBlockBraces cops
@tmaier
Copy link
Contributor Author

tmaier commented Mar 23, 2023

I think i've fixed the style errors

@tmaier
Copy link
Contributor Author

tmaier commented Mar 25, 2023

@rarruda I merged your suggestion re. Array#to_h.

However, this is only supported for Ruby >= 2.6
Ruby 2.6 and below already hit EoL. 2.7 is about to hit EoL in April this year.
I can either revert this last commit or you could remove officially the support for EoL Ruby versions.
This change would be out of scope for this PR.
See https://www.ruby-lang.org/en/downloads/branches/

@rarruda
Copy link
Collaborator

rarruda commented Mar 25, 2023

I should have tested the suggestion on 2.5 before mentioning it. Sorry about the extra work. My bad.

Let's revert and we can merge it as it was.

@tmaier
Copy link
Contributor Author

tmaier commented Mar 26, 2023

@rarruda no worries. I removed that last commit.

@rarruda rarruda merged commit 3165da3 into Unleash:main Mar 26, 2023
@rarruda
Copy link
Collaborator

rarruda commented Mar 26, 2023

@tmaier thanks for your contribution!

@tmaier tmaier deleted the patch-1 branch March 26, 2023 22:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Provide a #to_h method for Unleash::Context
4 participants