console-poker 1.0.1 → 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 71836d5b4ac6e60f30eea0d0d577b98df2b7914710437afcef444458fd1d4af4
4
- data.tar.gz: 58271e9022878cfc26385fefcac6c830a2b9cc0347124d0c9ab56a6e2f920529
3
+ metadata.gz: 4a339a0b7b3616879ad6ee0aeda14d25c8d314ac3160a259520931d87637aa0e
4
+ data.tar.gz: 172e3b67a5f578ebb6cac193b44660954f8a53c97bd43e874a233c5fefd1fc9d
5
5
  SHA512:
6
- metadata.gz: 6ab15f78da166b081bb1f1cf0596900275cac85749d74bdf478097bfc842f91c14f28966cb0392a9c1b59964f096bd2679473ce5db85bc2b57324c598b5db30e
7
- data.tar.gz: eef901bef6a08c542c2e00cdfc6c0b8c068c86e1cdbb9e5c92b75cea9d7996098453afc70bb8cd737a950c4edba398fa07aeb7cb33bc4e49e80058f62a6f98fb
6
+ metadata.gz: b39ed509a37c3d98f0528eae69ebeff390fb7d347a1e057a4b7982a38ca867591ed54296d6048225fc201f651e900da8c0d463b014c3ad23d90fa0896e4930bc
7
+ data.tar.gz: f45eeb3bbfcb2a67320c2bd9659c45eab434bb4f3563ddfc191682eb9e4f15c34201b975c315cce705d64e6dece2f65313f459d51b9949843f08188ab8701065
data/Gemfile CHANGED
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- ruby '3.1.2'
3
+ ruby '3.2.2'
4
4
 
5
5
  source 'https://rubygems.org'
6
6
 
data/Gemfile.lock CHANGED
@@ -1,66 +1,85 @@
1
1
  GEM
2
2
  remote: https://rubygems.org/
3
3
  specs:
4
- activesupport (7.0.4.3)
4
+ activesupport (7.1.2)
5
+ base64
6
+ bigdecimal
5
7
  concurrent-ruby (~> 1.0, >= 1.0.2)
8
+ connection_pool (>= 2.2.5)
9
+ drb
6
10
  i18n (>= 1.6, < 2)
7
11
  minitest (>= 5.1)
12
+ mutex_m
8
13
  tzinfo (~> 2.0)
9
14
  ast (2.4.2)
15
+ base64 (0.2.0)
16
+ bigdecimal (3.1.4)
10
17
  coderay (1.1.3)
11
18
  concurrent-ruby (1.2.2)
19
+ connection_pool (2.4.1)
12
20
  diff-lcs (1.5.0)
13
21
  docile (1.4.0)
14
- factory_bot (6.2.1)
22
+ drb (2.2.0)
23
+ ruby2_keywords
24
+ factory_bot (6.4.2)
15
25
  activesupport (>= 5.0.0)
16
- i18n (1.12.0)
26
+ i18n (1.14.1)
17
27
  concurrent-ruby (~> 1.0)
18
- json (2.6.3)
28
+ json (2.7.1)
29
+ language_server-protocol (3.17.0.3)
19
30
  method_source (1.0.0)
20
- minitest (5.18.0)
21
- parallel (1.22.1)
22
- parser (3.2.1.1)
31
+ minitest (5.20.0)
32
+ mutex_m (0.2.0)
33
+ parallel (1.23.0)
34
+ parser (3.2.2.4)
23
35
  ast (~> 2.4.1)
36
+ racc
24
37
  pry (0.14.2)
25
38
  coderay (~> 1.1)
26
39
  method_source (~> 1.0)
40
+ racc (1.7.3)
27
41
  rainbow (3.1.1)
28
- rake (13.0.6)
29
- regexp_parser (2.7.0)
30
- rexml (3.2.5)
42
+ rake (13.1.0)
43
+ regexp_parser (2.8.3)
44
+ rexml (3.2.6)
31
45
  rspec (3.12.0)
32
46
  rspec-core (~> 3.12.0)
33
47
  rspec-expectations (~> 3.12.0)
34
48
  rspec-mocks (~> 3.12.0)
35
- rspec-core (3.12.1)
49
+ rspec-core (3.12.2)
36
50
  rspec-support (~> 3.12.0)
37
- rspec-expectations (3.12.2)
51
+ rspec-expectations (3.12.3)
38
52
  diff-lcs (>= 1.2.0, < 2.0)
39
53
  rspec-support (~> 3.12.0)
40
- rspec-mocks (3.12.4)
54
+ rspec-mocks (3.12.6)
41
55
  diff-lcs (>= 1.2.0, < 2.0)
42
56
  rspec-support (~> 3.12.0)
43
- rspec-support (3.12.0)
44
- rubocop (1.48.1)
57
+ rspec-support (3.12.1)
58
+ rubocop (1.58.0)
45
59
  json (~> 2.3)
60
+ language_server-protocol (>= 3.17.0)
46
61
  parallel (~> 1.10)
47
- parser (>= 3.2.0.0)
62
+ parser (>= 3.2.2.4)
48
63
  rainbow (>= 2.2.2, < 4.0)
49
64
  regexp_parser (>= 1.8, < 3.0)
50
65
  rexml (>= 3.2.5, < 4.0)
51
- rubocop-ast (>= 1.26.0, < 2.0)
66
+ rubocop-ast (>= 1.30.0, < 2.0)
52
67
  ruby-progressbar (~> 1.7)
53
68
  unicode-display_width (>= 2.4.0, < 3.0)
54
- rubocop-ast (1.28.0)
69
+ rubocop-ast (1.30.0)
55
70
  parser (>= 3.2.1.0)
56
- rubocop-capybara (2.17.1)
71
+ rubocop-capybara (2.19.0)
57
72
  rubocop (~> 1.41)
73
+ rubocop-factory_bot (2.24.0)
74
+ rubocop (~> 1.33)
58
75
  rubocop-rake (0.6.0)
59
76
  rubocop (~> 1.0)
60
- rubocop-rspec (2.19.0)
61
- rubocop (~> 1.33)
77
+ rubocop-rspec (2.25.0)
78
+ rubocop (~> 1.40)
62
79
  rubocop-capybara (~> 2.17)
80
+ rubocop-factory_bot (~> 2.22)
63
81
  ruby-progressbar (1.13.0)
82
+ ruby2_keywords (0.0.5)
64
83
  simplecov (0.22.0)
65
84
  docile (~> 1.1)
66
85
  simplecov-html (~> 0.11)
@@ -69,10 +88,9 @@ GEM
69
88
  simplecov_json_formatter (0.1.4)
70
89
  tzinfo (2.0.6)
71
90
  concurrent-ruby (~> 1.0)
72
- unicode-display_width (2.4.2)
91
+ unicode-display_width (2.5.0)
73
92
 
74
93
  PLATFORMS
75
- arm64-darwin-21
76
94
  arm64-darwin-22
77
95
  x86_64-linux
78
96
 
@@ -87,7 +105,7 @@ DEPENDENCIES
87
105
  simplecov
88
106
 
89
107
  RUBY VERSION
90
- ruby 3.1.2p20
108
+ ruby 3.2.2p53
91
109
 
92
110
  BUNDLED WITH
93
- 2.3.15
111
+ 2.4.22
data/README.md CHANGED
@@ -17,7 +17,7 @@ Run:
17
17
  ## Status
18
18
 
19
19
  [![Ruby](https://github.com/gdonald/console-poker-ruby/workflows/Ruby/badge.svg)](https://github.com/gdonald/console-poker-ruby/actions)
20
- [![Downloads](https://ruby-gem-downloads-badge.herokuapp.com/console-poker?color=blue&type=total&total_label=)](https://rubygems.org/gems/console-poker)
20
+ [![Downloads](https://img.shields.io/gem/dt/console-poker?color=blue)](https://rubygems.org/gems/console-poker)
21
21
 
22
22
  ## License
23
23
 
Binary file
@@ -3,9 +3,9 @@
3
3
  require 'rake'
4
4
 
5
5
  Gem::Specification.new do |spec|
6
- spec.required_ruby_version = '>= 3.1'
6
+ spec.required_ruby_version = '>= 3.2'
7
7
  spec.name = 'console-poker'
8
- spec.version = '1.0.1'
8
+ spec.version = '1.0.2'
9
9
  spec.summary = 'Console Poker'
10
10
  spec.description = 'Poker for your console, full version.'
11
11
  spec.author = 'Greg Donald'
@@ -81,7 +81,7 @@ class HandRanker
81
81
  uniq_count_one?(vals, 3, 4)
82
82
  end
83
83
 
84
- def uniq_count_one?(array, *args)
85
- array.values_at(*args).uniq.count == 1
84
+ def uniq_count_one?(array, *)
85
+ array.values_at(*).uniq.count == 1
86
86
  end
87
87
  end
@@ -5,9 +5,7 @@ FactoryBot.define do
5
5
  poker { nil }
6
6
  cards { [] }
7
7
 
8
- trait :new_regular do
9
- after(:build, &:new_regular)
10
- end
8
+ after(:build, &:new_regular)
11
9
 
12
10
  initialize_with { new(poker) }
13
11
  end
@@ -10,7 +10,7 @@ FactoryBot.define do
10
10
  end
11
11
 
12
12
  trait :with_deck do
13
- deck { build(:deck, :new_regular) }
13
+ deck
14
14
  end
15
15
 
16
16
  initialize_with { new }
@@ -101,7 +101,7 @@ RSpec.describe Deck do
101
101
  end
102
102
 
103
103
  describe '#next_card' do
104
- let(:deck) { build(:deck, :new_regular, poker:) }
104
+ let(:deck) { build(:deck, poker:) }
105
105
 
106
106
  it 'removes the next card' do
107
107
  expect { deck.next_card }.to change(deck.cards, :size).by(-1)
@@ -28,7 +28,7 @@ RSpec.describe Hand do
28
28
  end
29
29
 
30
30
  describe '#pay' do
31
- context 'when a winning hand is unpayed' do
31
+ context 'when a winning hand is unpaid' do
32
32
  let(:hand) { build(:hand, :one_pair, poker:) }
33
33
 
34
34
  it 'adds the result to the poker money' do
@@ -38,7 +38,7 @@ RSpec.describe Hand do
38
38
  end
39
39
  end
40
40
 
41
- context 'when a losing hand is unpayed' do
41
+ context 'when a losing hand is unpaid' do
42
42
  let(:hand) { build(:hand, :unknown, poker:) }
43
43
 
44
44
  it 'subtracts the result from the poker money' do
@@ -48,7 +48,7 @@ RSpec.describe Hand do
48
48
  end
49
49
  end
50
50
 
51
- context 'when hand is already payed' do
51
+ context 'when hand is already paid' do
52
52
  before { hand.result = 500 }
53
53
 
54
54
  it 'ignores a hand with a result' do
@@ -2,7 +2,7 @@
2
2
 
3
3
  RSpec.describe Poker do
4
4
  let(:hand) { build(:hand, poker:) }
5
- let(:deck) { build(:deck, :new_regular) }
5
+ let(:deck) { build(:deck) }
6
6
  let(:poker) { build(:poker, deck:) }
7
7
  let(:input) { StringIO.new }
8
8
 
@@ -173,7 +173,7 @@ RSpec.describe Poker do
173
173
  end
174
174
  end
175
175
 
176
- context 'when the player hand is already payed' do
176
+ context 'when the player hand is already paid' do
177
177
  before do
178
178
  allow(poker).to receive(:build_new_hand)
179
179
  allow(hand).to receive(:ask_hand_action)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: console-poker
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Greg Donald
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-03-28 00:00:00.000000000 Z
11
+ date: 2023-12-09 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Poker for your console, full version.
14
14
  email: gdonald@gmail.com
@@ -24,6 +24,7 @@ files:
24
24
  - Rakefile
25
25
  - bin/console-poker
26
26
  - console-poker-1.0.0.gem
27
+ - console-poker-1.0.1.gem
27
28
  - console-poker.gemspec
28
29
  - lib/poker.rb
29
30
  - lib/poker/card.rb
@@ -65,14 +66,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
65
66
  requirements:
66
67
  - - ">="
67
68
  - !ruby/object:Gem::Version
68
- version: '3.1'
69
+ version: '3.2'
69
70
  required_rubygems_version: !ruby/object:Gem::Requirement
70
71
  requirements:
71
72
  - - ">="
72
73
  - !ruby/object:Gem::Version
73
74
  version: '0'
74
75
  requirements: []
75
- rubygems_version: 3.3.7
76
+ rubygems_version: 3.4.22
76
77
  signing_key:
77
78
  specification_version: 4
78
79
  summary: Console Poker