Skip to content

Instantly share code, notes, and snippets.

@ananth99
Created July 24, 2018 12:58
Show Gist options
  • Save ananth99/3713b396d6af4c6ac5305a25753cf4e8 to your computer and use it in GitHub Desktop.
Save ananth99/3713b396d6af4c6ac5305a25753cf4e8 to your computer and use it in GitHub Desktop.
export default {
Query: () => ({
keywordsByLocationId: () => new MockList(10),
listingsForLocation: () => new MockList(20),
duplicatesForLocation: () => new MockList(20),
}),
Mutation: () => ({
addKeywords: (root, args) => ({
ok: true,
keywords: addKeywordsResolver(args),
}),
starPhotosForLocation: (root, args) => ({
modifiedPhotos: starPhotosForLocationResolver(args),
}),
archiveKeyword: (root, args) => ({
keyword: archiveKeyword(args),
}),
}),
AddLocationPhotosPayload: () => ({
clientMutationId: faker.random.number(),
locationPhotos: [
{
name: 'Hello',
url: 'https://picsum.photos/200/300',
type: 'AdditionalImage',
},
],
}),
KeywordType: () => ({
id: faker.yrandom.number(100),
keyword: faker.name.firstName(),
}),
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment