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

Bugfix: Ensure credit_count is tested correctly #20654

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ gem "recaptcha", "~> 5.10", require: "recaptcha/rails" # Helpers for the reCAPTC
gem "redcarpet", "~> 3.5" # A fast, safe and extensible Markdown to (X)HTML parser

gem "redis", "~> 4.7.1" # Redis ruby client
gem "redis-actionpack", "~> 5.3.0" # Redis session store for ActionPack. Used for storing the Rails session in Redis.
gem "redis-actionpack", "~> 5.4.0" # Redis session store for ActionPack. Used for storing the Rails session in Redis.
gem "rpush", "~> 7.0" # Push Notification library for Rails
gem "rpush-redis", "~> 1.1" # Redis module capability for rpush library

Expand Down
18 changes: 10 additions & 8 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -636,6 +636,8 @@ GEM
rack
rack-protection (3.1.0)
rack (~> 2.2, >= 2.2.4)
rack-session (1.0.2)
rack (< 3)
rack-test (2.1.0)
rack (>= 1.3)
rack-timeout (0.6.3)
Expand Down Expand Up @@ -685,15 +687,15 @@ GEM
recaptcha (5.16.0)
redcarpet (3.6.0)
redis (4.7.1)
redis-actionpack (5.3.0)
redis-actionpack (5.4.0)
actionpack (>= 5, < 8)
redis-rack (>= 2.1.0, < 3)
redis-rack (>= 2.1.0, < 4)
redis-store (>= 1.1.0, < 2)
redis-rack (2.1.4)
rack (>= 2.0.8, < 3)
redis-rack (3.0.0)
rack-session (>= 0.2.0)
redis-store (>= 1.2, < 2)
redis-store (1.9.1)
redis (>= 4, < 5)
redis-store (1.10.0)
redis (>= 4, < 6)
regexp_parser (2.9.0)
reline (0.4.2)
io-console (~> 0.5)
Expand Down Expand Up @@ -893,7 +895,7 @@ GEM
dante (>= 0.2.0)
multi_json (~> 1.0)
stripe (> 5, < 6)
strong_migrations (1.5.0)
strong_migrations (1.7.0)
activerecord (>= 5.2)
terminal-table (3.0.2)
unicode-display_width (>= 1.1.1, < 3)
Expand Down Expand Up @@ -1079,7 +1081,7 @@ DEPENDENCIES
recaptcha (~> 5.10)
redcarpet (~> 3.5)
redis (~> 4.7.1)
redis-actionpack (~> 5.3.0)
redis-actionpack (~> 5.4.0)
request_store (~> 1.5)
reverse_markdown (~> 2.1)
rolify (~> 6.0)
Expand Down
4 changes: 2 additions & 2 deletions spec/models/credit_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
it { is_expected.to belong_to(:purchase).optional }

context "when caching counters" do
let(:user_credits) { create_list(:credit, 2, user: user) }
let(:org_credits) { create_list(:credit, 1, organization: organization) }
let!(:user_credits) { create_list(:credit, 2, user: user) }
let!(:org_credits) { create_list(:credit, 1, organization: organization) }

describe "#credits_count" do
it "counts credits for user" do
Expand Down
Binary file added vendor/cache/rack-session-1.0.2.gem
Binary file not shown.
Binary file removed vendor/cache/redis-actionpack-5.3.0.gem
Binary file not shown.
Binary file added vendor/cache/redis-actionpack-5.4.0.gem
Binary file not shown.
Binary file removed vendor/cache/redis-rack-2.1.4.gem
Binary file not shown.
Binary file added vendor/cache/redis-rack-3.0.0.gem
Binary file not shown.
Binary file added vendor/cache/redis-store-1.10.0.gem
Binary file not shown.
Binary file removed vendor/cache/redis-store-1.9.1.gem
Binary file not shown.
Binary file removed vendor/cache/strong_migrations-1.5.0.gem
Binary file not shown.
Binary file added vendor/cache/strong_migrations-1.7.0.gem
Binary file not shown.
Loading