TalentBox / sequel-rails

A gem for using Sequel with Rails 5.x, 6.x, 7.x, 8.x
http://talentbox.github.io/sequel-rails/
MIT License
326 stars 81 forks source link

feat: silence logger for sequel session store #171

Closed mjc-gh closed 5 years ago

mjc-gh commented 5 years ago

This PR silences the logger when reading and writing sessions to the database. This mimics behavior found in the ActiveRecord::SessionStore class.

Not sure how to best test this. Any suggestions?

JonathanTron commented 5 years ago

Hi @mjc-gh, thanks again for this new PR.

About testing it, you can probably do it in an integration test, changing the Sequel logger to output to a StringIO and adding your expectation on that after calling the code to exercise.

mjc-gh commented 5 years ago

@JonathanTron sounds good! I'll update this PR in the next day or two and get those specs in place. Thanks!

gencer commented 5 years ago

@JonathanTron, This should be merged because it exposes session data to the logs.

/cc @mjc-gh any update?

JonathanTron commented 5 years ago

Thanks @mjc-gh for the PR and @gencer for the push ;)