sportdb-structs 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Rakefile +3 -3
- data/lib/sportdb/structs.rb +21 -13
- data/lib/sportdb/structs/version.rb +1 -1
- data/test/helper.rb +2 -0
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0da18097a3c12d49e15eeb7963a4b62a030f4672
|
4
|
+
data.tar.gz: 75510bd91eb242f0617671bd115cced1e8e52c3c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8664d51d3ac92e5e1b214d459594806d83af703c8ee601ca37958ac23cbe1822b81396d03bca2f8c304f31cc3891e732dd7d2fc364ecf3218cee15a4565d51b4
|
7
|
+
data.tar.gz: 789287b40ef9f4c8359a3a241836ea2747a53a4406b70e652ca083aca766b96b481bcf2281a79ce88bb81887428139e27e33caa65e7bf741d5c18de78e767158
|
data/Rakefile
CHANGED
@@ -8,7 +8,7 @@ Hoe.spec 'sportdb-structs' do
|
|
8
8
|
self.summary = "sportdb-structs - sport data structures for matches, scores, leagues, seasons, rounds, groups, teams, clubs and more"
|
9
9
|
self.description = summary
|
10
10
|
|
11
|
-
self.urls =
|
11
|
+
self.urls = { home: 'https://github.com/sportdb/sport.db' }
|
12
12
|
|
13
13
|
self.author = 'Gerald Bauer'
|
14
14
|
self.email = 'opensport@googlegroups.com'
|
@@ -21,8 +21,8 @@ Hoe.spec 'sportdb-structs' do
|
|
21
21
|
|
22
22
|
self.extra_deps = [
|
23
23
|
['alphabets', '>= 1.0.0'],
|
24
|
-
['date-formats', '>= 1.0.
|
25
|
-
['score-formats', '>= 0.1.
|
24
|
+
['date-formats', '>= 1.0.2'],
|
25
|
+
['score-formats', '>= 0.1.1'],
|
26
26
|
['csvreader', '>= 1.2.4'],
|
27
27
|
['sportdb-langs', '>= 0.1.1'],
|
28
28
|
]
|
data/lib/sportdb/structs.rb
CHANGED
@@ -28,16 +28,36 @@ end
|
|
28
28
|
## more sportdb libs/gems
|
29
29
|
require 'sportdb/langs'
|
30
30
|
|
31
|
+
|
31
32
|
## todo/fix: move shortcut up to sportdb/langs!!!
|
32
33
|
module SportDb
|
33
34
|
Logging = LogUtils::Logging ## logging machinery shortcut; use LogUtils for now
|
34
35
|
end
|
35
36
|
|
37
|
+
## let's put test configuration in its own namespace / module
|
38
|
+
module SportDb
|
39
|
+
class Test ## todo/check: works with module too? use a module - why? why not?
|
40
|
+
|
41
|
+
####
|
42
|
+
# todo/fix: find a better way to configure shared test datasets - why? why not?
|
43
|
+
# note: use one-up (..) directory for now as default - why? why not?
|
44
|
+
def self.data_dir() @data_dir ||= '../test'; end
|
45
|
+
def self.data_dir=( path ) @data_dir = path; end
|
46
|
+
end
|
47
|
+
end # module SportDb
|
48
|
+
|
49
|
+
|
50
|
+
## todo/check: move up config to langs too - why? why not?
|
51
|
+
|
52
|
+
|
53
|
+
|
36
54
|
|
37
55
|
###
|
38
56
|
# our own code
|
39
57
|
require 'sportdb/structs/version' # let version always go first
|
40
|
-
require 'sportdb/structs/config'
|
58
|
+
require 'sportdb/structs/config' # let "global" config "framework" go next - why? why not?
|
59
|
+
|
60
|
+
|
41
61
|
require 'sportdb/structs/season'
|
42
62
|
|
43
63
|
require 'sportdb/structs/name_helper'
|
@@ -107,18 +127,6 @@ Football = Sports
|
|
107
127
|
|
108
128
|
|
109
129
|
|
110
|
-
## let's put test configuration in its own namespace / module
|
111
|
-
module SportDb
|
112
|
-
class Test ## todo/check: works with module too? use a module - why? why not?
|
113
|
-
|
114
|
-
####
|
115
|
-
# todo/fix: find a better way to configure shared test datasets - why? why not?
|
116
|
-
# note: use one-up (..) directory for now as default - why? why not?
|
117
|
-
def self.data_dir() @data_dir ||= '../test'; end
|
118
|
-
def self.data_dir=( path ) @data_dir = path; end
|
119
|
-
end
|
120
|
-
end # module SportDb
|
121
|
-
|
122
130
|
|
123
131
|
puts SportDb::Module::Structs.banner # say hello
|
124
132
|
|
data/test/helper.rb
CHANGED
@@ -1,6 +1,8 @@
|
|
1
1
|
## note: use the local version of sportdb gems
|
2
2
|
$LOAD_PATH.unshift( File.expand_path( '../date-formats/lib' ))
|
3
3
|
$LOAD_PATH.unshift( File.expand_path( '../score-formats/lib' ))
|
4
|
+
$LOAD_PATH.unshift( File.expand_path( '../sportdb-langs/lib' ))
|
5
|
+
|
4
6
|
|
5
7
|
## minitest setup
|
6
8
|
require 'minitest/autorun'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sportdb-structs
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gerald Bauer
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-09-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: alphabets
|
@@ -30,28 +30,28 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 1.0.
|
33
|
+
version: 1.0.2
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 1.0.
|
40
|
+
version: 1.0.2
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: score-formats
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
45
|
- - ">="
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: 0.1.
|
47
|
+
version: 0.1.1
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: 0.1.
|
54
|
+
version: 0.1.1
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: csvreader
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|