pokemon_tcg_sdk 4.2.0 → 4.2.1

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: 3e977885d8f2004da9c303adcc0a2a7ef7dc258089de75d44c6a41efba6261fd
4
- data.tar.gz: 88d8387350aa7a29d33e26895d4531efaf8787116b0335be4190feff510dff95
3
+ metadata.gz: 60b6d4cc3d9b6e2d724cd20cf3a071b97ebf29d798eec571ca5cf15f56d371f3
4
+ data.tar.gz: 8a193dc2a53be17d717989df61be54d2fd01afb2ae293782192062b2fa6127e0
5
5
  SHA512:
6
- metadata.gz: f7702e77d1aa11789704fa93932177f273ddebf90ff27272fce447e1aa5d8d326a6abe3b6d600a2f888362b45bca5597a2b03a6fd98188dc37b6f32bd3a87d13
7
- data.tar.gz: d081c1c24143b10d571be748b633b31dd8b15e5f593494c2bd1f875d732f1eb0ed433b6f5db8f0dee7da03677148cecc7f0344faf4ea45301aa79c297c17b2c2
6
+ metadata.gz: bfd9c8d0ee496a21a65322dcd8c497b5eaa850f0f70fd686ad89027cc859bb2a70ebc7215a6b64609079a5d72cb026e9b6baffa7c74de130ca1ec98f54539998
7
+ data.tar.gz: c4efab91945f943c3a83be792bf08c36ce7a234e3567e9340d451c803720646a17059c46503de45cd25ea5f7b5f08319f2a10da7404ca1187b135e205680feb3
@@ -0,0 +1,35 @@
1
+ # This workflow uses actions that are not certified by GitHub.
2
+ # They are provided by a third-party and are governed by
3
+ # separate terms of service, privacy policy, and support
4
+ # documentation.
5
+ # This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
6
+ # For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby
7
+
8
+ name: Test
9
+
10
+ on:
11
+ push:
12
+ branches: [ master ]
13
+ pull_request:
14
+ branches: [ master ]
15
+
16
+ jobs:
17
+ test:
18
+
19
+ runs-on: ubuntu-latest
20
+ strategy:
21
+ matrix:
22
+ ruby-version: ['2.6', '2.7', '3.0']
23
+
24
+ steps:
25
+ - uses: actions/checkout@v2
26
+ - name: Set up Ruby
27
+ # To automatically get bug fixes and new Ruby versions for ruby/setup-ruby,
28
+ # change this to (see https://github.com/ruby/setup-ruby#versioning):
29
+ # uses: ruby/setup-ruby@v1
30
+ uses: ruby/setup-ruby@473e4d8fe5dd94ee328fdfca9f8c9c7afc9dae5e
31
+ with:
32
+ ruby-version: ${{ matrix.ruby-version }}
33
+ bundler-cache: true # runs 'bundle install' and caches installed gems automatically
34
+ - name: Run tests
35
+ run: bundle exec rake test
data/README.md CHANGED
@@ -1,10 +1,7 @@
1
1
  # Pokémon TCG SDK
2
2
 
3
3
  [![Gem Version](https://badge.fury.io/rb/pokemon_tcg_sdk.svg)](https://badge.fury.io/rb/pokemon_tcg_sdk)
4
- [![Build Status](https://travis-ci.org/PokemonTCG/pokemon-tcg-sdk-ruby.svg?branch=master)](https://travis-ci.org/PokemonTCG/pokemon-tcg-sdk-ruby)
5
- [![Dependency Status](https://gemnasium.com/badges/github.com/PokemonTCG/pokemon-tcg-sdk-ruby.svg)](https://gemnasium.com/github.com/PokemonTCG/pokemon-tcg-sdk-ruby)
6
- [![Code Climate](https://codeclimate.com/github/PokemonTCG/pokemon-tcg-sdk-ruby/badges/gpa.svg)](https://codeclimate.com/github/PokemonTCG/pokemon-tcg-sdk-ruby)
7
- [![Test Coverage](https://api.codeclimate.com/v1/badges/ee9d7d6ee5f8276729bc/test_coverage)](https://codeclimate.com/github/PokemonTCG/pokemon-tcg-sdk-ruby/test_coverage)
4
+ ![Build Status](https://github.com/PokemonTCG/pokemon-tcg-sdk-ruby/actions/workflows/test.yml/badge.svg)
8
5
 
9
6
  ### Now supporting Version 2 of the Pokémon TCG API!
10
7
 
@@ -51,7 +51,7 @@ module Pokemon
51
51
  if !fetch_all
52
52
  break
53
53
  else
54
- where(page: page += 1)
54
+ @query.merge!(page: page += 1)
55
55
  end
56
56
  else
57
57
  break
@@ -31,9 +31,12 @@ module Pokemon
31
31
  protected
32
32
 
33
33
  def self.client
34
+ headers = {'Content-Type' => 'application/json'}
35
+ headers['X-Api-Key'] = Pokemon.configuration.api_key unless Pokemon.configuration.api_key.nil?
36
+
34
37
  @client = Faraday.new(
35
38
  url: "#{API_URL}/v2",
36
- headers: {'Content-Type' => 'application/json', 'X-Api-Key' => Pokemon.configuration.api_key}
39
+ headers: headers
37
40
  )
38
41
  end
39
42
 
@@ -1,3 +1,3 @@
1
1
  module Pokemon
2
- VERSION = "4.2.0"
2
+ VERSION = "4.2.1"
3
3
  end
@@ -17,7 +17,7 @@ Gem::Specification.new do |spec|
17
17
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
18
18
  spec.require_paths = ["lib"]
19
19
 
20
- spec.add_development_dependency "bundler", "~> 2.1.4"
20
+ spec.add_development_dependency "bundler", "~> 2.2.11"
21
21
  spec.add_development_dependency "rake", "~> 13.0"
22
22
  spec.add_development_dependency "minitest", "~> 5.14.2"
23
23
  spec.add_development_dependency "vcr", "~> 6.0"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pokemon_tcg_sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.2.0
4
+ version: 4.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Backes
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-02-10 00:00:00.000000000 Z
11
+ date: 2021-02-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 2.1.4
19
+ version: 2.2.11
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 2.1.4
26
+ version: 2.2.11
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -172,8 +172,8 @@ extensions: []
172
172
  extra_rdoc_files: []
173
173
  files:
174
174
  - ".editorconfig"
175
+ - ".github/workflows/test.yml"
175
176
  - ".gitignore"
176
- - ".travis.yml"
177
177
  - CODE_OF_CONDUCT.md
178
178
  - Gemfile
179
179
  - LICENSE.txt
data/.travis.yml DELETED
@@ -1,15 +0,0 @@
1
- env:
2
- global:
3
- - CC_TEST_REPORTER_ID=c14dfc2c8a10a029ac3706d2c2c86f63f663a1445df6213e013a42cbc9a55e74
4
- language: ruby
5
- rvm:
6
- - 2.7.0
7
- before_install: gem install bundler -v 2.1.4
8
- before_script:
9
- - curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
10
- - chmod +x ./cc-test-reporter
11
- - ./cc-test-reporter before-build
12
- script:
13
- - rake test
14
- after_script:
15
- - ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT