diff --git a/.github/workflows/assistant-release-e2e-workflow.yml b/.github/workflows/assistant-release-e2e-workflow.yml index 952fd4cdd..3afca290f 100644 --- a/.github/workflows/assistant-release-e2e-workflow.yml +++ b/.github/workflows/assistant-release-e2e-workflow.yml @@ -22,4 +22,4 @@ jobs: with: test-name: dashboards assistant test-command: env CYPRESS_DASHBOARDS_ASSISTANT_ENABLED=true yarn cypress:run-with-security --browser chromium --spec 'cypress/integration/plugins/dashboards-assistant/*' - osd-serve-args: --assistant.chat.enabled=true --assistant.chat.rootAgentName="Cypress test agent" + osd-serve-args: --assistant.chat.enabled=true diff --git a/cypress/utils/plugins/dashboards-assistant/commands.js b/cypress/utils/plugins/dashboards-assistant/commands.js index 8197c9d80..9028bd6a0 100644 --- a/cypress/utils/plugins/dashboards-assistant/commands.js +++ b/cypress/utils/plugins/dashboards-assistant/commands.js @@ -112,6 +112,16 @@ Cypress.Commands.add('registerRootAgent', () => { }) .then((resp) => { agentParameters.rootAgentId = resp.body.agent_id; + return cy.request( + 'POST', + `${BACKEND_BASE_PATH}${ML_COMMONS_API.UPDATE_ROOT_AGENT_CONFIG}`, + { + type: 'os_chat_root_agent', + configuration: { + agent_id: agentParameters.rootAgentId, + }, + } + ); }); }); diff --git a/cypress/utils/plugins/dashboards-assistant/constants.js b/cypress/utils/plugins/dashboards-assistant/constants.js index c8340b5ed..2e941cf93 100644 --- a/cypress/utils/plugins/dashboards-assistant/constants.js +++ b/cypress/utils/plugins/dashboards-assistant/constants.js @@ -14,6 +14,7 @@ export const ML_COMMONS_API = { CREATE_CONNECTOR: `${ML_COMMONS_API_PREFIX}/connectors/_create`, CREATE_MODEL: `${ML_COMMONS_API_PREFIX}/models/_register`, CREATE_AGENT: `${ML_COMMONS_API_PREFIX}/agents/_register`, + UPDATE_ROOT_AGENT_CONFIG: `.plugins-ml-config/_doc/os_chat`, }; export const ASSISTANT_API_BASE = '/api/assistant';