diff options
Diffstat (limited to 'spec/frontend/clusters_list/mocks/apollo.js')
-rw-r--r-- | spec/frontend/clusters_list/mocks/apollo.js | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/spec/frontend/clusters_list/mocks/apollo.js b/spec/frontend/clusters_list/mocks/apollo.js index c4a31ed4394..b0f2978a230 100644 --- a/spec/frontend/clusters_list/mocks/apollo.js +++ b/spec/frontend/clusters_list/mocks/apollo.js @@ -10,6 +10,9 @@ const token = { const tokens = { nodes: [token], }; +const connections = { + nodes: [], +}; const pageInfo = { endCursor: '', hasNextPage: false, @@ -23,6 +26,7 @@ export const createAgentResponse = { createClusterAgent: { clusterAgent: { ...agent, + connections, tokens, }, errors: [], @@ -35,6 +39,7 @@ export const createAgentErrorResponse = { createClusterAgent: { clusterAgent: { ...agent, + connections, tokens, }, errors: ['could not create agent'], @@ -65,8 +70,9 @@ export const createAgentTokenErrorResponse = { export const getAgentResponse = { data: { project: { + __typename: 'Project', id: 'project-1', - clusterAgents: { nodes: [{ ...agent, tokens }], pageInfo, count }, + clusterAgents: { nodes: [{ ...agent, connections, tokens }], pageInfo, count }, repository: { tree: { trees: { nodes: [{ ...agent, path: null }], pageInfo }, @@ -76,6 +82,11 @@ export const getAgentResponse = { }, }; +export const kasDisabledErrorResponse = { + data: {}, + errors: [{ message: 'Gitlab::Kas::Client::ConfigurationError' }], +}; + export const mockDeleteResponse = { data: { clusterAgentDelete: { errors: [] } }, }; |