Skip to content

Commit

Permalink
feat: Get Apollo Federation to work with GraphQL 1.13.x (#160)
Browse files Browse the repository at this point in the history
* Stop using the legacy graphql_definition method

* Add GraphQL 1.1.3 to the appraisal matrix

* Reconcile gemfiles with main

* support for graphql-ruby v1.13 (#147)

* GraphQL Ruby deals with arity, we don't have to pass args

Co-authored-by: Tomoki Ichikawa <[email protected]>
  • Loading branch information
daemonsy and 1060ki authored Feb 4, 2022
1 parent 9f695a9 commit 800001b
Show file tree
Hide file tree
Showing 6 changed files with 143 additions and 5 deletions.
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -102,11 +102,11 @@ workflows:
- ruby-test:
matrix:
parameters:
appraisal: ['graphql-1.10', 'graphql-1.11', 'graphql-1.12']
appraisal: ['graphql-1.10', 'graphql-1.11', 'graphql-1.12', 'graphql-1.13']
- integration-tests:
matrix:
parameters:
appraisal: ['graphql-1.10', 'graphql-1.11', 'graphql-1.12']
appraisal: ['graphql-1.10', 'graphql-1.11', 'graphql-1.12', 'graphql-1.13']
- release:
requires:
- gusto/ruby-lint
Expand Down
4 changes: 4 additions & 0 deletions Appraisals
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,7 @@ end
appraise 'graphql-1.12' do
gem 'graphql', '1.12.5'
end

appraise 'graphql-1.13' do
gem 'graphql', '~> 1.13.6'
end
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ GEM
debase-ruby_core_source (0.10.9)
diff-lcs (1.3)
erubi (1.9.0)
google-protobuf (3.19.4-x86_64-linux)
google-protobuf (3.19.4)
graphql (1.10.14)
i18n (1.8.5)
concurrent-ruby (~> 1.0)
Expand Down
7 changes: 7 additions & 0 deletions gemfiles/graphql_1.13.gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# This file was generated by Appraisal

source "https://rubygems.org"

gem "graphql", "~> 1.13.6"

gemspec path: "../"
128 changes: 128 additions & 0 deletions gemfiles/graphql_1.13.gemfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,128 @@
PATH
remote: ..
specs:
apollo-federation (2.1.0)
google-protobuf (~> 3.19)
graphql (>= 1.10.14)

GEM
remote: https://rubygems.org/
specs:
actionpack (6.1.4.4)
actionview (= 6.1.4.4)
activesupport (= 6.1.4.4)
rack (~> 2.0, >= 2.0.9)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.2.0)
actionview (6.1.4.4)
activesupport (= 6.1.4.4)
builder (~> 3.1)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.1, >= 1.2.0)
activesupport (6.1.4.4)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 1.6, < 2)
minitest (>= 5.1)
tzinfo (~> 2.0)
zeitwerk (~> 2.3)
appraisal (2.4.1)
bundler
rake
thor (>= 0.14.0)
ast (2.4.2)
builder (3.2.4)
byebug (11.1.3)
coderay (1.1.3)
concurrent-ruby (1.1.9)
crass (1.0.6)
debase (0.2.4.1)
debase-ruby_core_source (>= 0.10.2)
debase-ruby_core_source (0.10.14)
diff-lcs (1.5.0)
erubi (1.10.0)
google-protobuf (3.19.4)
graphql (1.13.6)
i18n (1.9.1)
concurrent-ruby (~> 1.0)
jaro_winkler (1.5.4)
loofah (2.13.0)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
method_source (1.0.0)
mini_portile2 (2.7.1)
minitest (5.15.0)
nokogiri (1.13.1)
mini_portile2 (~> 2.7.0)
racc (~> 1.4)
parallel (1.21.0)
parser (3.1.0.0)
ast (~> 2.4.1)
pry (0.13.1)
coderay (~> 1.1)
method_source (~> 1.0)
pry-byebug (3.9.0)
byebug (~> 11.0)
pry (~> 0.13.0)
racc (1.6.0)
rack (2.2.3)
rack-test (1.1.0)
rack (>= 1.0, < 3)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.4.2)
loofah (~> 2.3)
rainbow (3.1.1)
rake (13.0.6)
rspec (3.10.0)
rspec-core (~> 3.10.0)
rspec-expectations (~> 3.10.0)
rspec-mocks (~> 3.10.0)
rspec-core (3.10.1)
rspec-support (~> 3.10.0)
rspec-expectations (3.10.2)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.10.0)
rspec-mocks (3.10.2)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.10.0)
rspec-support (3.10.3)
rubocop (0.72.0)
jaro_winkler (~> 1.5.1)
parallel (~> 1.10)
parser (>= 2.6)
rainbow (>= 2.2.2, < 4.0)
ruby-progressbar (~> 1.7)
unicode-display_width (>= 1.4.0, < 1.7)
rubocop-rspec (1.41.0)
rubocop (>= 0.68.1)
ruby-debug-ide (0.7.3)
rake (>= 0.8.1)
ruby-progressbar (1.11.0)
thor (1.2.1)
tzinfo (2.0.4)
concurrent-ruby (~> 1.0)
unicode-display_width (1.6.1)
zeitwerk (2.5.4)

PLATFORMS
ruby

DEPENDENCIES
actionpack
apollo-federation!
appraisal
debase
graphql (~> 1.13.6)
pry-byebug
rack
rake
rspec
rubocop (~> 0.72.0)
rubocop-rspec
ruby-debug-ide

BUNDLED WITH
2.3.6
3 changes: 1 addition & 2 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@

RSpec::Matchers.define :match_sdl do |expected|
match do |actual|
@actual = "#{actual}\n"
@actual == expected
actual.chomp == expected.chomp
end

diffable
Expand Down

0 comments on commit 800001b

Please sign in to comment.