Skip to content

Commit

Permalink
Update gems and javascript modules
Browse files Browse the repository at this point in the history
  • Loading branch information
ddnexus committed Nov 5, 2024
1 parent 5818b57 commit 3de9224
Show file tree
Hide file tree
Showing 2 changed files with 79 additions and 79 deletions.
126 changes: 63 additions & 63 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6,29 +6,29 @@ PATH
GEM
remote: https://rubygems.org/
specs:
actioncable (7.2.1.2)
actionpack (= 7.2.1.2)
activesupport (= 7.2.1.2)
actioncable (7.2.2)
actionpack (= 7.2.2)
activesupport (= 7.2.2)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
zeitwerk (~> 2.6)
actionmailbox (7.2.1.2)
actionpack (= 7.2.1.2)
activejob (= 7.2.1.2)
activerecord (= 7.2.1.2)
activestorage (= 7.2.1.2)
activesupport (= 7.2.1.2)
actionmailbox (7.2.2)
actionpack (= 7.2.2)
activejob (= 7.2.2)
activerecord (= 7.2.2)
activestorage (= 7.2.2)
activesupport (= 7.2.2)
mail (>= 2.8.0)
actionmailer (7.2.1.2)
actionpack (= 7.2.1.2)
actionview (= 7.2.1.2)
activejob (= 7.2.1.2)
activesupport (= 7.2.1.2)
actionmailer (7.2.2)
actionpack (= 7.2.2)
actionview (= 7.2.2)
activejob (= 7.2.2)
activesupport (= 7.2.2)
mail (>= 2.8.0)
rails-dom-testing (~> 2.2)
actionpack (7.2.1.2)
actionview (= 7.2.1.2)
activesupport (= 7.2.1.2)
actionpack (7.2.2)
actionview (= 7.2.2)
activesupport (= 7.2.2)
nokogiri (>= 1.8.5)
racc
rack (>= 2.2.4, < 3.2)
Expand All @@ -37,36 +37,37 @@ GEM
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
useragent (~> 0.16)
actiontext (7.2.1.2)
actionpack (= 7.2.1.2)
activerecord (= 7.2.1.2)
activestorage (= 7.2.1.2)
activesupport (= 7.2.1.2)
actiontext (7.2.2)
actionpack (= 7.2.2)
activerecord (= 7.2.2)
activestorage (= 7.2.2)
activesupport (= 7.2.2)
globalid (>= 0.6.0)
nokogiri (>= 1.8.5)
actionview (7.2.1.2)
activesupport (= 7.2.1.2)
actionview (7.2.2)
activesupport (= 7.2.2)
builder (~> 3.1)
erubi (~> 1.11)
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
activejob (7.2.1.2)
activesupport (= 7.2.1.2)
activejob (7.2.2)
activesupport (= 7.2.2)
globalid (>= 0.3.6)
activemodel (7.2.1.2)
activesupport (= 7.2.1.2)
activerecord (7.2.1.2)
activemodel (= 7.2.1.2)
activesupport (= 7.2.1.2)
activemodel (7.2.2)
activesupport (= 7.2.2)
activerecord (7.2.2)
activemodel (= 7.2.2)
activesupport (= 7.2.2)
timeout (>= 0.4.0)
activestorage (7.2.1.2)
actionpack (= 7.2.1.2)
activejob (= 7.2.1.2)
activerecord (= 7.2.1.2)
activesupport (= 7.2.1.2)
activestorage (7.2.2)
actionpack (= 7.2.2)
activejob (= 7.2.2)
activerecord (= 7.2.2)
activesupport (= 7.2.2)
marcel (~> 1.0)
activesupport (7.2.1.2)
activesupport (7.2.2)
base64
benchmark (>= 0.3)
bigdecimal
concurrent-ruby (~> 1.0, >= 1.3.1)
connection_pool (>= 2.2.5)
Expand All @@ -81,12 +82,13 @@ GEM
ansi (1.5.0)
ast (2.4.2)
base64 (0.2.0)
benchmark (0.3.0)
bigdecimal (3.1.8)
builder (3.3.0)
concurrent-ruby (1.3.4)
connection_pool (2.4.1)
crass (1.0.6)
date (3.3.4)
date (3.4.0)
docile (1.4.1)
domain_name (0.6.20240107)
drb (2.2.1)
Expand Down Expand Up @@ -115,7 +117,7 @@ GEM
irb (1.14.1)
rdoc (>= 4.0.0)
reline (>= 0.4.2)
json (2.7.4)
json (2.7.6)
language_server-protocol (3.17.0.3)
listen (3.9.0)
rb-fsevent (~> 0.10, >= 0.10.3)
Expand Down Expand Up @@ -158,12 +160,12 @@ GEM
racc (~> 1.4)
nokogiri (1.16.7-x86_64-linux)
racc (~> 1.4)
oj (3.16.6)
oj (3.16.7)
bigdecimal (>= 3.0)
ostruct (>= 0.2)
ostruct (0.6.0)
parallel (1.26.3)
parser (3.3.5.0)
parser (3.3.5.1)
ast (~> 2.4.1)
racc
psych (5.1.2)
Expand All @@ -180,33 +182,32 @@ GEM
rack (>= 3.0.0)
rack-test (2.1.0)
rack (>= 1.3)
rackup (2.1.0)
rackup (2.2.0)
rack (>= 3)
webrick (~> 1.8)
rails (7.2.1.2)
actioncable (= 7.2.1.2)
actionmailbox (= 7.2.1.2)
actionmailer (= 7.2.1.2)
actionpack (= 7.2.1.2)
actiontext (= 7.2.1.2)
actionview (= 7.2.1.2)
activejob (= 7.2.1.2)
activemodel (= 7.2.1.2)
activerecord (= 7.2.1.2)
activestorage (= 7.2.1.2)
activesupport (= 7.2.1.2)
rails (7.2.2)
actioncable (= 7.2.2)
actionmailbox (= 7.2.2)
actionmailer (= 7.2.2)
actionpack (= 7.2.2)
actiontext (= 7.2.2)
actionview (= 7.2.2)
activejob (= 7.2.2)
activemodel (= 7.2.2)
activerecord (= 7.2.2)
activestorage (= 7.2.2)
activesupport (= 7.2.2)
bundler (>= 1.15.0)
railties (= 7.2.1.2)
railties (= 7.2.2)
rails-dom-testing (2.2.0)
activesupport (>= 5.0.0)
minitest
nokogiri (>= 1.6)
rails-html-sanitizer (1.6.0)
loofah (~> 2.21)
nokogiri (~> 1.14)
railties (7.2.1.2)
actionpack (= 7.2.1.2)
activesupport (= 7.2.1.2)
railties (7.2.2)
actionpack (= 7.2.2)
activesupport (= 7.2.2)
irb (~> 1.13)
rackup (>= 1.0.0)
rake (>= 12.2)
Expand All @@ -226,7 +227,7 @@ GEM
rerun (0.14.0)
listen (~> 3.0)
rouge (4.4.0)
rubocop (1.67.0)
rubocop (1.68.0)
json (~> 2.3)
language_server-protocol (>= 3.17.0)
parallel (~> 1.10)
Expand All @@ -236,7 +237,7 @@ GEM
rubocop-ast (>= 1.32.2, < 2.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 2.4.0, < 3.0)
rubocop-ast (1.32.3)
rubocop-ast (1.34.0)
parser (>= 3.3.1.0)
rubocop-minitest (0.36.0)
rubocop (>= 1.61, < 2.0)
Expand All @@ -251,7 +252,7 @@ GEM
ruby-progressbar (1.13.0)
ruby2_keywords (0.0.5)
securerandom (0.3.1)
sequel (5.85.0)
sequel (5.86.0)
bigdecimal
simplecov (0.22.0)
docile (~> 1.1)
Expand Down Expand Up @@ -280,7 +281,6 @@ GEM
concurrent-ruby (~> 1.0)
unicode-display_width (2.6.0)
useragent (0.16.10)
webrick (1.8.2)
websocket-driver (0.7.6)
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.5)
Expand Down
32 changes: 16 additions & 16 deletions test/pagy/extras/overflow_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,15 @@
_(@pagy_countless).must_be :overflow?
end
it 'is not overflow?' do
_(Pagy.new(**pagy_vars.merge(page: 2))).wont_be :overflow?
_(Pagy::Countless.new(**pagy_vars.merge(page: 2))).wont_be :overflow?
_(Pagy::Calendar::Day.new(**calendar_vars.merge(page: 2))).wont_be :overflow?
_(Pagy.new(**pagy_vars, page: 2)).wont_be :overflow?
_(Pagy::Countless.new(**pagy_vars, page: 2)).wont_be :overflow?
_(Pagy::Calendar::Day.new(**calendar_vars, page: 2)).wont_be :overflow?
end
end

describe '#initialize' do
it 'works in :last_page mode in Pagy' do
pagy = Pagy.new(**pagy_vars.merge(overflow: :last_page))
pagy = Pagy.new(**pagy_vars, overflow: :last_page)
_(pagy).must_be_instance_of Pagy
_(pagy.pages).must_equal 11
_(pagy.page).must_equal pagy.last
Expand All @@ -54,7 +54,7 @@
_(pagy.prev).must_equal 10
end
it 'works in :last_page mode in Pagy::Calendar' do
pagy = Pagy::Calendar::Day.new(**calendar_vars.merge(overflow: :last_page))
pagy = Pagy::Calendar::Day.new(**calendar_vars, overflow: :last_page)
_(pagy).must_be_instance_of Pagy::Calendar::Day
_(pagy.pages).must_equal 11
_(pagy.page).must_equal pagy.last
Expand All @@ -64,12 +64,12 @@
_(pagy.prev).must_equal 10
end
it 'raises OverflowError in :exception mode' do
_ { Pagy.new(**pagy_vars.merge(overflow: :exception)) }.must_raise Pagy::OverflowError
_ { Pagy::Calendar::Day.new(**calendar_vars.merge(overflow: :exception)) }.must_raise Pagy::OverflowError
_ { Pagy::Countless.new(**countless_vars.merge(overflow: :exception)).finalize(0) }.must_raise Pagy::OverflowError
_ { Pagy.new(**pagy_vars, overflow: :exception) }.must_raise Pagy::OverflowError
_ { Pagy::Calendar::Day.new(**calendar_vars, overflow: :exception) }.must_raise Pagy::OverflowError
_ { Pagy::Countless.new(**countless_vars, overflow: :exception).finalize(0) }.must_raise Pagy::OverflowError
end
it 'works in :empty_page mode in Pagy' do
pagy = Pagy.new(**pagy_vars.merge(overflow: :empty_page))
pagy = Pagy.new(**pagy_vars, overflow: :empty_page)
_(pagy.page).must_equal 100
_(pagy.offset).must_equal 990
_(pagy.limit).must_equal 10
Expand All @@ -79,12 +79,12 @@
_(pagy.prev).must_equal pagy.last
end
it 'works in :empty_page mode in Pagy::Calendar' do
pagy = Pagy::Calendar::Day.new(**calendar_vars.merge(overflow: :empty_page))
pagy = Pagy::Calendar::Day.new(**calendar_vars, overflow: :empty_page)
_(pagy.page).must_equal 100
_(pagy.from).must_equal pagy.instance_variable_get(:@final)
_(pagy.to).must_equal pagy.instance_variable_get(:@final)
_(pagy.prev).must_equal pagy.last
pagy = Pagy::Calendar::Day.new(**calendar_vars.merge(overflow: :empty_page, order: :desc))
pagy = Pagy::Calendar::Day.new(**calendar_vars, overflow: :empty_page, order: :desc)
_(pagy.page).must_equal 100
_(pagy.from).must_equal pagy.instance_variable_get(:@initial)
_(pagy.to).must_equal pagy.instance_variable_get(:@initial)
Expand All @@ -101,21 +101,21 @@
_(pagy.prev).must_be_nil
end
it 'raises Pagy::VariableError' do
_ { Pagy.new(**pagy_vars.merge(overflow: :unknown)) }.must_raise Pagy::VariableError
_ { Pagy::Calendar::Day.new(**calendar_vars.merge(overflow: :unknown)) }.must_raise Pagy::VariableError
_ { Pagy::Countless.new(**countless_vars.merge(overflow: :unknown)).finalize(0) }.must_raise Pagy::VariableError
_ { Pagy.new(**pagy_vars, overflow: :unknown) }.must_raise Pagy::VariableError
_ { Pagy::Calendar::Day.new(**calendar_vars, overflow: :unknown) }.must_raise Pagy::VariableError
_ { Pagy::Countless.new(**countless_vars, overflow: :unknown).finalize(0) }.must_raise Pagy::VariableError
end
end

describe "#series singleton for :empty_page mode" do
it 'computes series for empty page for Pagy' do
pagy = Pagy.new(**pagy_vars.merge(overflow: :empty_page))
pagy = Pagy.new(**pagy_vars, overflow: :empty_page)
series = pagy.series
_(series).must_equal [1, :gap, 7, 8, 9, 10, 11]
_(pagy.page).must_equal 100
end
it 'computes series for empty page for Pagy::Calendar' do
pagy = Pagy::Calendar::Day.new(**calendar_vars.merge(overflow: :empty_page))
pagy = Pagy::Calendar::Day.new(**calendar_vars, overflow: :empty_page)
series = pagy.series
_(series).must_equal([1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11])
_(pagy.page).must_equal 100
Expand Down

0 comments on commit 3de9224

Please sign in to comment.