mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-17 12:31:52 +03:00
1d1de94303
* change login flow to handle admin secret persistence * handle headers init state * add tooltip for remember-me * remove log, make label clickable * fix a closure scope bug * handle login verification at route level * update Login.js * refactor * remove extra file * refactor * add id to tooltips * remove adminsecretlabel + update admin secret storage flow * fix heartIcon close handling * . * fix admin secret setting * fix urlPrefix * add admin secret header if not present * update jwt analyzer icon * persist if admin secret header has already been added * set cli console mode as constant * handle CLI admin secret errors * make separate logout page * fix typos * fix typos * fix typos * fix typos * fix cli error * fix login page path
24 lines
894 B
JavaScript
24 lines
894 B
JavaScript
import { ADMIN_SECRET_HEADER_KEY } from '../../src/constants';
|
|
|
|
export const baseUrl = Cypress.config('baseUrl');
|
|
export const queryTypes = ['insert', 'update', 'delete'];
|
|
export const getTriggerName = (i, testName = '') =>
|
|
`Apic_test_trigger_${testName}_${i}`;
|
|
export const getTableName = (i, testName = '') =>
|
|
`Apic_test_table_${testName}_${i}`;
|
|
export const getWebhookURL = () => 'http://httpbin.org/post';
|
|
export const getNoOfRetries = () => '5';
|
|
export const getIntervalSeconds = () => '10';
|
|
export const getTimeoutSeconds = () => '25';
|
|
export const getElementFromAlias = alias => `[data-test=${alias}]`;
|
|
export const makeDataAPIUrl = dataApiUrl => `${dataApiUrl}/v1/query`;
|
|
export const makeDataAPIOptions = (dataApiUrl, key, body) => ({
|
|
method: 'POST',
|
|
url: makeDataAPIUrl(dataApiUrl),
|
|
headers: {
|
|
[ADMIN_SECRET_HEADER_KEY]: key,
|
|
},
|
|
body,
|
|
failOnStatusCode: false,
|
|
});
|