rr_games_radar 1.0.2 → 1.0.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -44,6 +44,17 @@ module GamesRadarApi
44
44
  response.game[:publishers] = response.game.publishers.us
45
45
  end
46
46
 
47
+ if response.game.description.nil? or response.game.description.empty?
48
+ response.game[:description] = nil
49
+ else
50
+ response.game[:description] = response.game.description
51
+ end
52
+
53
+ if response.game.censorship.nil?
54
+ response.game[:esrb] = nil
55
+ else
56
+ response.game[:esrb] = response.game.censorship.esrb.rating
57
+ end
47
58
  end
48
59
 
49
60
  return response.game unless response.game.nil? or response.game.id.nil?
@@ -1,3 +1,3 @@
1
1
  module GamesRadarApi
2
- VERSION = "1.0.2"
2
+ VERSION = "1.0.3"
3
3
  end
@@ -47,6 +47,11 @@ describe GamesRadarApi::Client::Games do
47
47
  response = @client.game('16725')
48
48
  response.genre.must_equal("Action")
49
49
  end
50
+
51
+ it "should return name of esrb" do
52
+ response = @client.game('16725')
53
+ response.esrb.must_equal("Mature")
54
+ end
50
55
  end
51
56
 
52
57
  describe 'Game Search' do
@@ -61,8 +66,6 @@ describe GamesRadarApi::Client::Games do
61
66
  response = @client.game_search('Darksdiers','xbox360')
62
67
  response.must_be_nil
63
68
  end
64
-
65
-
66
69
  end
67
70
 
68
71
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rr_games_radar
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.0.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: