integration

package
v0.7.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 5, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RepoRoot

func RepoRoot(t *testing.T) string

RepoRoot returns the root of the genqlient repository,

func RunGenerateTest

func RunGenerateTest(t *testing.T, relConfigFilename string)

RunGenerateTest checks that running genqlient with the given repo-root-relative config file would not produce any changes to the checked-in files.

Types

type AnimalFields

type AnimalFields struct {
	Id    string                     `json:"id"`
	Hair  AnimalFieldsHairBeingsHair `json:"hair"`
	Owner AnimalFieldsOwnerBeing     `json:"-"`
}

AnimalFields includes the GraphQL fields of Animal requested by the fragment AnimalFields.

func (*AnimalFields) GetHair added in v0.4.0

GetHair returns AnimalFields.Hair, and is useful for accessing the field via an interface.

func (*AnimalFields) GetId added in v0.4.0

func (v *AnimalFields) GetId() string

GetId returns AnimalFields.Id, and is useful for accessing the field via an interface.

func (*AnimalFields) GetOwner added in v0.4.0

func (v *AnimalFields) GetOwner() AnimalFieldsOwnerBeing

GetOwner returns AnimalFields.Owner, and is useful for accessing the field via an interface.

func (*AnimalFields) MarshalJSON added in v0.3.0

func (v *AnimalFields) MarshalJSON() ([]byte, error)

func (*AnimalFields) UnmarshalJSON

func (v *AnimalFields) UnmarshalJSON(b []byte) error

type AnimalFieldsHairBeingsHair

type AnimalFieldsHairBeingsHair struct {
	HasHair bool `json:"hasHair"`
}

AnimalFieldsHairBeingsHair includes the requested fields of the GraphQL type BeingsHair.

func (*AnimalFieldsHairBeingsHair) GetHasHair added in v0.4.0

func (v *AnimalFieldsHairBeingsHair) GetHasHair() bool

GetHasHair returns AnimalFieldsHairBeingsHair.HasHair, and is useful for accessing the field via an interface.

type AnimalFieldsOwnerAnimal

type AnimalFieldsOwnerAnimal struct {
	Typename string `json:"__typename"`
	Id       string `json:"id"`
}

AnimalFieldsOwnerAnimal includes the requested fields of the GraphQL type Animal.

func (*AnimalFieldsOwnerAnimal) GetId

func (v *AnimalFieldsOwnerAnimal) GetId() string

GetId returns AnimalFieldsOwnerAnimal.Id, and is useful for accessing the field via an interface.

func (*AnimalFieldsOwnerAnimal) GetTypename

func (v *AnimalFieldsOwnerAnimal) GetTypename() string

GetTypename returns AnimalFieldsOwnerAnimal.Typename, and is useful for accessing the field via an interface.

type AnimalFieldsOwnerBeing

type AnimalFieldsOwnerBeing interface {

	// GetTypename returns the receiver's concrete GraphQL type-name (see interface doc for possible values).
	GetTypename() string
	// GetId returns the interface-field "id" from its implementation.
	GetId() string
	// contains filtered or unexported methods
}

AnimalFieldsOwnerBeing includes the requested fields of the GraphQL interface Being.

AnimalFieldsOwnerBeing is implemented by the following types: AnimalFieldsOwnerAnimal AnimalFieldsOwnerUser

type AnimalFieldsOwnerUser

type AnimalFieldsOwnerUser struct {
	Typename        string `json:"__typename"`
	Id              string `json:"id"`
	UserFields      `json:"-"`
	LuckyFieldsUser `json:"-"`
}

AnimalFieldsOwnerUser includes the requested fields of the GraphQL type User.

func (*AnimalFieldsOwnerUser) GetHair added in v0.4.0

GetHair returns AnimalFieldsOwnerUser.Hair, and is useful for accessing the field via an interface.

func (*AnimalFieldsOwnerUser) GetId

func (v *AnimalFieldsOwnerUser) GetId() string

GetId returns AnimalFieldsOwnerUser.Id, and is useful for accessing the field via an interface.

func (*AnimalFieldsOwnerUser) GetLuckyNumber added in v0.4.0

func (v *AnimalFieldsOwnerUser) GetLuckyNumber() int

GetLuckyNumber returns AnimalFieldsOwnerUser.LuckyNumber, and is useful for accessing the field via an interface.

func (*AnimalFieldsOwnerUser) GetTypename

func (v *AnimalFieldsOwnerUser) GetTypename() string

GetTypename returns AnimalFieldsOwnerUser.Typename, and is useful for accessing the field via an interface.

func (*AnimalFieldsOwnerUser) MarshalJSON added in v0.3.0

func (v *AnimalFieldsOwnerUser) MarshalJSON() ([]byte, error)

func (*AnimalFieldsOwnerUser) UnmarshalJSON

func (v *AnimalFieldsOwnerUser) UnmarshalJSON(b []byte) error

type FriendsFields added in v0.3.0

type FriendsFields struct {
	Id   string `json:"id"`
	Name string `json:"name"`
}

FriendsFields includes the GraphQL fields of User requested by the fragment FriendsFields.

func (*FriendsFields) GetId added in v0.4.0

func (v *FriendsFields) GetId() string

GetId returns FriendsFields.Id, and is useful for accessing the field via an interface.

func (*FriendsFields) GetName added in v0.4.0

func (v *FriendsFields) GetName() string

GetName returns FriendsFields.Name, and is useful for accessing the field via an interface.

type InnerBeingFields added in v0.3.0

type InnerBeingFields interface {

	// GetId returns the interface-field "id" from its implementation.
	GetId() string
	// GetName returns the interface-field "name" from its implementation.
	GetName() string
	// contains filtered or unexported methods
}

InnerBeingFields includes the GraphQL fields of Being requested by the fragment InnerBeingFields.

InnerBeingFields is implemented by the following types: InnerBeingFieldsAnimal InnerBeingFieldsUser

type InnerBeingFieldsAnimal added in v0.3.0

type InnerBeingFieldsAnimal struct {
	Id   string `json:"id"`
	Name string `json:"name"`
}

InnerBeingFields includes the GraphQL fields of Animal requested by the fragment InnerBeingFields.

func (*InnerBeingFieldsAnimal) GetId added in v0.3.0

func (v *InnerBeingFieldsAnimal) GetId() string

GetId returns InnerBeingFieldsAnimal.Id, and is useful for accessing the field via an interface.

func (*InnerBeingFieldsAnimal) GetName added in v0.3.0

func (v *InnerBeingFieldsAnimal) GetName() string

GetName returns InnerBeingFieldsAnimal.Name, and is useful for accessing the field via an interface.

type InnerBeingFieldsUser added in v0.3.0

type InnerBeingFieldsUser struct {
	Id      string          `json:"id"`
	Name    string          `json:"name"`
	Friends []FriendsFields `json:"friends"`
}

InnerBeingFields includes the GraphQL fields of User requested by the fragment InnerBeingFields.

func (*InnerBeingFieldsUser) GetFriends added in v0.4.0

func (v *InnerBeingFieldsUser) GetFriends() []FriendsFields

GetFriends returns InnerBeingFieldsUser.Friends, and is useful for accessing the field via an interface.

func (*InnerBeingFieldsUser) GetId added in v0.3.0

func (v *InnerBeingFieldsUser) GetId() string

GetId returns InnerBeingFieldsUser.Id, and is useful for accessing the field via an interface.

func (*InnerBeingFieldsUser) GetName added in v0.3.0

func (v *InnerBeingFieldsUser) GetName() string

GetName returns InnerBeingFieldsUser.Name, and is useful for accessing the field via an interface.

type InnerLuckyFields added in v0.3.0

type InnerLuckyFields interface {

	// GetLuckyNumber returns the interface-field "luckyNumber" from its implementation.
	GetLuckyNumber() int
	// contains filtered or unexported methods
}

InnerLuckyFields includes the GraphQL fields of Lucky requested by the fragment InnerLuckyFields.

InnerLuckyFields is implemented by the following types: InnerLuckyFieldsUser

type InnerLuckyFieldsUser added in v0.3.0

type InnerLuckyFieldsUser struct {
	LuckyNumber int `json:"luckyNumber"`
}

InnerLuckyFields includes the GraphQL fields of User requested by the fragment InnerLuckyFields.

func (*InnerLuckyFieldsUser) GetLuckyNumber added in v0.3.0

func (v *InnerLuckyFieldsUser) GetLuckyNumber() int

GetLuckyNumber returns InnerLuckyFieldsUser.LuckyNumber, and is useful for accessing the field via an interface.

type LuckyFields

type LuckyFields interface {

	// GetLuckyNumber returns the interface-field "luckyNumber" from its implementation.
	GetLuckyNumber() int
	// contains filtered or unexported methods
}

LuckyFields includes the GraphQL fields of Lucky requested by the fragment LuckyFields.

LuckyFields is implemented by the following types: LuckyFieldsUser

type LuckyFieldsUser

type LuckyFieldsUser struct {
	MoreUserFields `json:"-"`
	LuckyNumber    int `json:"luckyNumber"`
}

LuckyFields includes the GraphQL fields of User requested by the fragment LuckyFields.

func (*LuckyFieldsUser) GetHair added in v0.4.0

func (v *LuckyFieldsUser) GetHair() MoreUserFieldsHair

GetHair returns LuckyFieldsUser.Hair, and is useful for accessing the field via an interface.

func (*LuckyFieldsUser) GetId added in v0.4.0

func (v *LuckyFieldsUser) GetId() string

GetId returns LuckyFieldsUser.Id, and is useful for accessing the field via an interface.

func (*LuckyFieldsUser) GetLuckyNumber

func (v *LuckyFieldsUser) GetLuckyNumber() int

GetLuckyNumber returns LuckyFieldsUser.LuckyNumber, and is useful for accessing the field via an interface.

func (*LuckyFieldsUser) MarshalJSON added in v0.3.0

func (v *LuckyFieldsUser) MarshalJSON() ([]byte, error)

func (*LuckyFieldsUser) UnmarshalJSON

func (v *LuckyFieldsUser) UnmarshalJSON(b []byte) error

type MoreUserFields

type MoreUserFields struct {
	Id   string             `json:"id"`
	Hair MoreUserFieldsHair `json:"hair"`
}

MoreUserFields includes the GraphQL fields of User requested by the fragment MoreUserFields.

func (*MoreUserFields) GetHair added in v0.4.0

func (v *MoreUserFields) GetHair() MoreUserFieldsHair

GetHair returns MoreUserFields.Hair, and is useful for accessing the field via an interface.

func (*MoreUserFields) GetId added in v0.4.0

func (v *MoreUserFields) GetId() string

GetId returns MoreUserFields.Id, and is useful for accessing the field via an interface.

type MoreUserFieldsHair

type MoreUserFieldsHair struct {
	Color string `json:"color"`
}

MoreUserFieldsHair includes the requested fields of the GraphQL type Hair.

func (*MoreUserFieldsHair) GetColor added in v0.4.0

func (v *MoreUserFieldsHair) GetColor() string

GetColor returns MoreUserFieldsHair.Color, and is useful for accessing the field via an interface.

type MyGreatScalar added in v0.7.0

type MyGreatScalar string

Used for a binding in genqlient.yaml.

This is here rather than in testutil to test the case where the generated code and the bound type are in the same package.

type NewUser added in v0.5.0

type NewUser struct {
	Name string `json:"name"`
}

func (*NewUser) GetName added in v0.5.0

func (v *NewUser) GetName() string

GetName returns NewUser.Name, and is useful for accessing the field via an interface.

type QueryFragment added in v0.3.0

type QueryFragment struct {
	Beings []QueryFragmentBeingsBeing `json:"-"`
}

QueryFragment includes the GraphQL fields of Query requested by the fragment QueryFragment.

func (*QueryFragment) GetBeings added in v0.4.0

func (v *QueryFragment) GetBeings() []QueryFragmentBeingsBeing

GetBeings returns QueryFragment.Beings, and is useful for accessing the field via an interface.

func (*QueryFragment) MarshalJSON added in v0.3.0

func (v *QueryFragment) MarshalJSON() ([]byte, error)

func (*QueryFragment) UnmarshalJSON added in v0.3.0

func (v *QueryFragment) UnmarshalJSON(b []byte) error

type QueryFragmentBeingsAnimal added in v0.3.0

type QueryFragmentBeingsAnimal struct {
	Typename string           `json:"__typename"`
	Id       string           `json:"id"`
	Owner    InnerBeingFields `json:"-"`
}

QueryFragmentBeingsAnimal includes the requested fields of the GraphQL type Animal.

func (*QueryFragmentBeingsAnimal) GetId added in v0.3.0

func (v *QueryFragmentBeingsAnimal) GetId() string

GetId returns QueryFragmentBeingsAnimal.Id, and is useful for accessing the field via an interface.

func (*QueryFragmentBeingsAnimal) GetOwner added in v0.4.0

GetOwner returns QueryFragmentBeingsAnimal.Owner, and is useful for accessing the field via an interface.

func (*QueryFragmentBeingsAnimal) GetTypename added in v0.3.0

func (v *QueryFragmentBeingsAnimal) GetTypename() string

GetTypename returns QueryFragmentBeingsAnimal.Typename, and is useful for accessing the field via an interface.

func (*QueryFragmentBeingsAnimal) MarshalJSON added in v0.3.0

func (v *QueryFragmentBeingsAnimal) MarshalJSON() ([]byte, error)

func (*QueryFragmentBeingsAnimal) UnmarshalJSON added in v0.3.0

func (v *QueryFragmentBeingsAnimal) UnmarshalJSON(b []byte) error

type QueryFragmentBeingsBeing added in v0.3.0

type QueryFragmentBeingsBeing interface {

	// GetTypename returns the receiver's concrete GraphQL type-name (see interface doc for possible values).
	GetTypename() string
	// GetId returns the interface-field "id" from its implementation.
	GetId() string
	// contains filtered or unexported methods
}

QueryFragmentBeingsBeing includes the requested fields of the GraphQL interface Being.

QueryFragmentBeingsBeing is implemented by the following types: QueryFragmentBeingsAnimal QueryFragmentBeingsUser

type QueryFragmentBeingsUser added in v0.3.0

type QueryFragmentBeingsUser struct {
	Typename             string `json:"__typename"`
	Id                   string `json:"id"`
	InnerLuckyFieldsUser `json:"-"`
}

QueryFragmentBeingsUser includes the requested fields of the GraphQL type User.

func (*QueryFragmentBeingsUser) GetId added in v0.3.0

func (v *QueryFragmentBeingsUser) GetId() string

GetId returns QueryFragmentBeingsUser.Id, and is useful for accessing the field via an interface.

func (*QueryFragmentBeingsUser) GetLuckyNumber added in v0.4.0

func (v *QueryFragmentBeingsUser) GetLuckyNumber() int

GetLuckyNumber returns QueryFragmentBeingsUser.LuckyNumber, and is useful for accessing the field via an interface.

func (*QueryFragmentBeingsUser) GetTypename added in v0.3.0

func (v *QueryFragmentBeingsUser) GetTypename() string

GetTypename returns QueryFragmentBeingsUser.Typename, and is useful for accessing the field via an interface.

func (*QueryFragmentBeingsUser) MarshalJSON added in v0.3.0

func (v *QueryFragmentBeingsUser) MarshalJSON() ([]byte, error)

func (*QueryFragmentBeingsUser) UnmarshalJSON added in v0.3.0

func (v *QueryFragmentBeingsUser) UnmarshalJSON(b []byte) error

type Species

type Species string
const (
	SpeciesDog        Species = "DOG"
	SpeciesCoelacanth Species = "COELACANTH"
)

type UserFields

type UserFields struct {
	Id              string `json:"id"`
	LuckyFieldsUser `json:"-"`
	MoreUserFields  `json:"-"`
}

UserFields includes the GraphQL fields of User requested by the fragment UserFields.

func (*UserFields) GetHair added in v0.4.0

func (v *UserFields) GetHair() MoreUserFieldsHair

GetHair returns UserFields.Hair, and is useful for accessing the field via an interface.

func (*UserFields) GetId added in v0.4.0

func (v *UserFields) GetId() string

GetId returns UserFields.Id, and is useful for accessing the field via an interface.

func (*UserFields) GetLuckyNumber added in v0.4.0

func (v *UserFields) GetLuckyNumber() int

GetLuckyNumber returns UserFields.LuckyNumber, and is useful for accessing the field via an interface.

func (*UserFields) MarshalJSON added in v0.3.0

func (v *UserFields) MarshalJSON() ([]byte, error)

func (*UserFields) UnmarshalJSON

func (v *UserFields) UnmarshalJSON(b []byte) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL