crunchbase-ruby-library 0.1.2 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/crunchbase/api.rb +1 -1
- data/lib/crunchbase/version.rb +1 -1
- data/spec/crunchbase/model/organization_spec.rb +48 -36
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c707cf870a56439dbdb02b2a3776ea010d816dce
|
4
|
+
data.tar.gz: c5599efb47f3d19fb3b3651b7db33e17d3425e34
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7f71393e8a2b90723621c772d1fe51cadd48fbfd1869af347b76a5cf9006e1b28d0c97b83f583428fb3e073a9a9932478d3e5bbe2dcc6d1d0ac488f1210f8bdb
|
7
|
+
data.tar.gz: 847912b8b82e84b69269d8fa4cdbf0a42df5ff03b31733f458e7d7e841126d71418da4832ddb610f1a9009edc1eb28bfa873f778c3d2c7876864fc1d630e6138
|
data/lib/crunchbase/api.rb
CHANGED
@@ -135,7 +135,7 @@ module Crunchbase
|
|
135
135
|
def self.get_url_following_redirects(uri_str, limit = 10)
|
136
136
|
raise Crunchbase::Exception, 'HTTP redirect too deep' if limit == 0
|
137
137
|
|
138
|
-
uri = URI.parse(uri_str)
|
138
|
+
uri = URI.parse(URI.encode(uri_str))
|
139
139
|
|
140
140
|
debug_log!(uri) if debug
|
141
141
|
|
data/lib/crunchbase/version.rb
CHANGED
@@ -5,56 +5,68 @@ module Crunchbase
|
|
5
5
|
|
6
6
|
describe Organization do
|
7
7
|
|
8
|
-
|
9
|
-
|
8
|
+
context "organization with i18n name" do
|
9
|
+
before(:all) do
|
10
|
+
@organization = Organization.get("bon-appétit")
|
11
|
+
end
|
12
|
+
|
13
|
+
it 'returns organization data' do
|
14
|
+
expect(@organization.name).to eq("Bon Appétit")
|
15
|
+
end
|
10
16
|
end
|
11
17
|
|
12
|
-
|
13
|
-
|
14
|
-
|
18
|
+
context "TODO" do
|
19
|
+
before(:all) do
|
20
|
+
@organization = Organization.get("abovenet")
|
21
|
+
end
|
15
22
|
|
16
|
-
|
17
|
-
|
18
|
-
|
23
|
+
it 'show all products name' do
|
24
|
+
puts @organization.products.map { |i| i.name }.inspect unless @organization.products.nil?
|
25
|
+
end
|
19
26
|
|
20
|
-
|
21
|
-
|
22
|
-
|
27
|
+
it 'show all offices name' do
|
28
|
+
puts @organization.offices.map { |i| i.name }.inspect unless @organization.offices.nil?
|
29
|
+
end
|
23
30
|
|
24
|
-
|
25
|
-
|
26
|
-
|
31
|
+
it 'show all funding_rounds funding_type' do
|
32
|
+
puts @organization.funding_rounds.map { |i| i.funding_type }.inspect unless @organization.funding_rounds.nil?
|
33
|
+
end
|
27
34
|
|
28
|
-
|
29
|
-
|
30
|
-
|
35
|
+
it 'show all competitors name' do
|
36
|
+
puts @organization.competitors.map { |i| i.name }.inspect unless @organization.competitors.nil?
|
37
|
+
end
|
31
38
|
|
32
|
-
|
33
|
-
|
34
|
-
|
39
|
+
it 'show all investments money_invested' do
|
40
|
+
puts @organization.investments.map { |i| i.money_invested }.inspect unless @organization.investments.nil?
|
41
|
+
end
|
35
42
|
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
end
|
43
|
+
it 'show all acquisitions acquiree name' do
|
44
|
+
puts @organization.acquisitions.map { |i| i.acquiree.name }.inspect unless @organization.acquisitions.nil?
|
45
|
+
end
|
40
46
|
|
41
|
-
|
42
|
-
|
43
|
-
|
47
|
+
it 'show all ipo funded_company name' do
|
48
|
+
puts "IPOs - #{@organization.ipo_total_items.nil?}"
|
49
|
+
puts @organization.ipo.map { |i| i.funded_company.name }.inspect unless @organization.ipo.nil?
|
50
|
+
end
|
44
51
|
|
45
|
-
|
46
|
-
|
47
|
-
|
52
|
+
it "show all categories name" do
|
53
|
+
puts @organization.categories.map {|i| i.name }.inspect unless @organization.categories.nil?
|
54
|
+
end
|
48
55
|
|
49
|
-
|
50
|
-
|
51
|
-
|
56
|
+
it "show all news name" do
|
57
|
+
puts @organization.news.map {|i| i.title }.inspect unless @organization.news.nil?
|
58
|
+
end
|
59
|
+
|
60
|
+
it "show all current_team members name" do
|
61
|
+
puts @organization.current_team.map {|i| [i.title, i.person.last_name] }.inspect unless @organization.current_team.nil?
|
62
|
+
end
|
52
63
|
|
53
|
-
|
54
|
-
|
64
|
+
it "show all websites website" do
|
65
|
+
puts @organization.websites.map {|i| i.website }.inspect unless @organization.websites.nil?
|
66
|
+
end
|
55
67
|
end
|
56
68
|
|
57
69
|
end
|
58
70
|
|
59
71
|
end
|
60
|
-
end
|
72
|
+
end
|