-
Notifications
You must be signed in to change notification settings - Fork 18
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
Use redis in tests instead of fakeredis #32
Conversation
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.
Thank you!
See for some review nitpicks below ↓
spec/redis_helper.rb
Outdated
# frozen_string_literal: true | ||
|
||
def configure_test_redis_db | ||
url = ENV.fetch("REDIS_URL", "redis://localhost:6379/6") # AnyCable uses Redis DB number 5 by default |
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.
redis://localhost:6379/*6*
and AnyCable uses Redis DB number 5 by default
? 🤔
url = ENV.fetch("REDIS_URL", "redis://localhost:6379/6") # AnyCable uses Redis DB number 5 by default | |
url = ENV.fetch("REDIS_URL", "redis://localhost:6379/5") # AnyCable uses Redis DB number 5 by default |
README.md
Outdated
4. Pass redis-server URL to AnyCable using ENV variables | ||
|
||
```bash | ||
REDIS_URL=redis://localhost:6379/5 bundle exec rspec | ||
``` | ||
|
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.
Maybe move test-specific things to a different section, not to mix with general use configuration?
Thanks a lot! |
* origin/master: Use real Redis in tests instead of fakeredis gem (anycable#32)
…dling * master: Switch to RubyGems Trusted publishing in CI release workflow [ci skip] add emergency actions TO README fix: consider redis_prefix in GraphQL::AnyCable::Cleaner add ability to set scan_count and added a little refactoring ability to fetch subscription stats use "around" instead "before" little refactoring add changes to README remove override redis_prefix and add an extra spec feat: Add configurable graphql redis_prefix Support empty operation name with redis.rb v5 (#34) Use arrays to fix deprecation warnings with redis gem 4.8 (#29) Use real Redis in tests instead of fakeredis gem (#32) Better `config.use_client_provided_uniq_id` deprecation (#27) Delay the deprecation warning of use_client_provided_uniq_id (#26)
TODO: