mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-15 17:31:56 +03:00
3879e65e7d
PR-URL: https://github.com/hasura/graphql-engine-mono/pull/3852 Co-authored-by: Vijay Prasanna <11921040+vijayprasanna13@users.noreply.github.com> GitOrigin-RevId: 275df81b75cf3db255b25a8adf2c1e7df9e31ded
18 lines
598 B
TypeScript
18 lines
598 B
TypeScript
export const replaceMetadata = (newMetadata: Record<string, any>) => {
|
|
const postBody = { type: 'replace_metadata', args: newMetadata };
|
|
cy.request('POST', 'http://localhost:8080/v1/metadata', postBody).then(
|
|
response => {
|
|
expect(response.body).to.have.property('message', 'success'); // true
|
|
}
|
|
);
|
|
};
|
|
|
|
export const resetMetadata = () => {
|
|
const postBody = { type: 'clear_metadata', args: {} };
|
|
cy.request('POST', 'http://localhost:8080/v1/metadata', postBody).then(
|
|
response => {
|
|
expect(response.body).to.have.property('message', 'success'); // true
|
|
}
|
|
);
|
|
};
|