Sha256: afe82809eb3351bbf404bb4fc36e05aee767a4de3bb757c0a85b0e0193549749

Contents?: true

Size: 787 Bytes

Versions: 5

Compression:

Stored size: 787 Bytes

Contents

require 'integration/config'

class Integration_SQLite_StarWarsIntrospectionTest < GraphQL::IntegrationTestCase
  load_schema 'sqlite'

  SCHEMA = ::StartWarsSqliteSchema

  def test_auto_introspection
    assert(SCHEMA.introspection?)
    assert(SCHEMA.has_field?(:query, :__schema))
    assert(SCHEMA.has_field?(:query, :__type))
  end

  # Test this spec with all available scalars
  def remove_keys_form_type_map
  end

  # There are some issues with the end sorting, so compare the string result
  # with sorted characters, which will produce the exact match
  def test_gql_introspection
    # File.write('test/assets/sqlite.gql', SCHEMA.to_gql)
    result = gql_file('sqlite').split('').sort.join.squish
    assert_equal(result, SCHEMA.to_gql.split('').sort.join.squish)
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
rails-graphql-1.0.2 test/integration/sqlite/star_wars_introspection_test.rb
rails-graphql-1.0.1 test/integration/sqlite/star_wars_introspection_test.rb
rails-graphql-1.0.0 test/integration/sqlite/star_wars_introspection_test.rb
rails-graphql-1.0.0.rc2 test/integration/sqlite/star_wars_introspection_test.rb
rails-graphql-1.0.0.rc1 test/integration/sqlite/star_wars_introspection_test.rb