3 Star 4 Fork 0

Gitee 极速下载/OpenSearch-Dashboards

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
此仓库是为了提升国内下载速度的镜像仓库,每日同步一次。 原始仓库: https://github.com/opensearch-project/OpenSearch-Dashboards
克隆/下载
cypress.config.ts 2.47 KB
一键复制 编辑 原始数据 按行查看 历史
Joey Liu 提交于 2025-04-11 02:49 +08:00 . [TEST] Add saved search related test cases (#9656)
/*
* Copyright OpenSearch Contributors
* SPDX-License-Identifier: Apache-2.0
*/
import { defineConfig } from 'cypress';
import webpackPreprocessor from '@cypress/webpack-preprocessor';
// TODO: import { paste } from 'copy-paste';
module.exports = defineConfig({
experimentalMemoryManagement: true,
numTestsKeptInMemory: 0,
defaultCommandTimeout: 15000,
requestTimeout: 60000,
responseTimeout: 60000,
retries: {
runMode: 2,
openMode: 0,
},
viewportWidth: 1920,
viewportHeight: 1080,
env: {
ENGINE: {
name: 'default',
url: 'http://localhost:9200',
},
SECONDARY_ENGINE: {
name: 'test_cluster',
url: 'http://localhost:9200',
},
S3_ENGINE: {
name: 'BasicS3Connection',
url: process.env.S3_CONNECTION_URL,
username: process.env.S3_CONNECTION_USERNAME,
password: process.env.S3_CONNECTION_PASSWORD,
},
openSearchUrl: 'http://localhost:9200',
SECURITY_ENABLED: false,
AGGREGATION_VIEW: false,
username: 'admin',
password: 'myStrongPassword123!',
ENDPOINT_WITH_PROXY: false,
MANAGED_SERVICE_ENDPOINT: false,
VISBUILDER_ENABLED: true,
DATASOURCE_MANAGEMENT_ENABLED: false,
ML_COMMONS_DASHBOARDS_ENABLED: true,
WAIT_FOR_LOADER_BUFFER_MS: 0,
WAIT_MS: 2000,
DISABLE_LOCAL_CLUSTER: false,
CYPRESS_RUNTIME_ENV: 'osd',
},
e2e: {
baseUrl: 'http://localhost:5601',
specPattern: 'cypress/integration/**/*.spec.{js,jsx,ts,tsx}',
testIsolation: false,
setupNodeEvents,
},
});
function setupNodeEvents(
on: Cypress.PluginEvents,
config: Cypress.PluginConfigOptions
): Cypress.PluginConfigOptions {
const { webpackOptions } = webpackPreprocessor.defaultOptions;
/**
* By default, cypress' internal webpack preprocessor doesn't allow imports without file extensions.
* This makes our life a bit hard since if any file in our testing dependency graph has an import without
* the .js extension our cypress build will fail.
*
* This extra rule relaxes this a bit by allowing imports without file extension
* ex. import module from './module'
*/
webpackOptions!.module!.rules.unshift({
test: /\.m?js/,
resolve: {
enforceExtension: false,
},
});
on(
'file:preprocessor',
webpackPreprocessor({
webpackOptions,
})
);
// TODO: Define the custom task to read clipboard
/* on('task', {
readClipboard() {
return paste(); // Return the clipboard content
},
});*/
return config;
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
JavaScript
1
https://gitee.com/mirrors/OpenSearch-Dashboards.git
git@gitee.com:mirrors/OpenSearch-Dashboards.git
mirrors
OpenSearch-Dashboards
OpenSearch-Dashboards
main

搜索帮助