basketball 0.0.23 → 0.0.25
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/basketball/season/calendar.rb +3 -3
- data/lib/basketball/season/league.rb +1 -1
- data/lib/basketball/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e02bf31c8332d0d1010f8ad9ff18cb09ddd3f97e4a7cefcb14ddf11d38633d67
|
4
|
+
data.tar.gz: 9c4b3b0e1771c0a4d22e8c83ba9040089fae019f3726c8cda55ddecbb3d69fa1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 65a444b460b134eeceecea00213a0e4887dc635b7d012f402e09404e4d3e2dea44931810f413da167ae72ea6fb9e2b1533aea4691d3b5d99ba841709388f95e0
|
7
|
+
data.tar.gz: b193b20e0ba49d4cf4686150cc7abef344a3289bcefdeb4bfc168e57e2eb8f1c6d776e3eafdc6a618096ea29e0ae9d3e94d96b3c78f341efc461efab6f746b16
|
@@ -4,7 +4,7 @@ module Basketball
|
|
4
4
|
module Season
|
5
5
|
# Sets boundaries for exhibition and regular season play. Add games as long as they are
|
6
6
|
# within the correct dated boundaries
|
7
|
-
class Calendar
|
7
|
+
class Calendar < Entity
|
8
8
|
class OutOfBoundsError < StandardError; end
|
9
9
|
class TeamAlreadyBookedError < StandardError; end
|
10
10
|
|
@@ -21,6 +21,8 @@ module Basketball
|
|
21
21
|
regular_end_date:,
|
22
22
|
games: []
|
23
23
|
)
|
24
|
+
super()
|
25
|
+
|
24
26
|
raise ArgumentError, 'exhibition_start_date is required' if exhibition_start_date.to_s.empty?
|
25
27
|
raise ArgumentError, 'exhibition_end_date is required' if exhibition_end_date.to_s.empty?
|
26
28
|
raise ArgumentError, 'regular_start_date is required' if regular_start_date.to_s.empty?
|
@@ -33,8 +35,6 @@ module Basketball
|
|
33
35
|
@games = []
|
34
36
|
|
35
37
|
games.each { |game| add!(game) }
|
36
|
-
|
37
|
-
freeze
|
38
38
|
end
|
39
39
|
|
40
40
|
def add!(game)
|
data/lib/basketball/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: basketball
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.25
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matthew Ruggio
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-06-
|
11
|
+
date: 2023-06-30 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: " This library is meant to serve as the domain for a basketball league/season
|
14
14
|
simulator/turn-based game. It models core ideas such as: players, general managers,
|