({
description,
title,
}: {
description: string
title: string
})
| 2634 | |
| 2635 | describe('Collections - GraphQL', () => { |
| 2636 | async function createAutoSavePostHelper({ |
| 2637 | description, |
| 2638 | title, |
| 2639 | }: { |
| 2640 | description: string |
| 2641 | title: string |
| 2642 | }): Promise<JsonObject> { |
| 2643 | const query = `mutation { |
| 2644 | createAutosavePost(data: {title: "${title}", description: "${description}"}) { |
| 2645 | id |
| 2646 | title |
| 2647 | description |
| 2648 | createdAt |
| 2649 | updatedAt |
| 2650 | _status |
| 2651 | } |
| 2652 | }` |
| 2653 | |
| 2654 | const result: JsonObject = await restClient |
| 2655 | .GRAPHQL_POST({ |
| 2656 | body: JSON.stringify({ query }), |
| 2657 | }) |
| 2658 | .then((res) => res.json()) |
| 2659 | |
| 2660 | return result.data.createAutosavePost |
| 2661 | } |
| 2662 | |
| 2663 | async function updateAutoSavePostHelper({ |
| 2664 | id, |
no test coverage detected
searching dependent graphs…