From 35253c8127fcef65564a4a6c48ad0db220a0c740 Mon Sep 17 00:00:00 2001 From: jtubau Date: Wed, 19 Feb 2025 12:39:30 +0100 Subject: [PATCH 1/3] test: refs #8618 added e2e test to routeExtendedList --- cypress.config.js | 11 + src/components/common/VnInputDate.vue | 1 + src/pages/Route/RouteExtendedList.vue | 5 +- .../route/routeExtendedList.spec.js | 198 ++++++++++++++++++ 4 files changed, 214 insertions(+), 1 deletion(-) create mode 100644 test/cypress/integration/route/routeExtendedList.spec.js diff --git a/cypress.config.js b/cypress.config.js index a9e27fcfd..26b7725a5 100644 --- a/cypress.config.js +++ b/cypress.config.js @@ -34,6 +34,17 @@ export default defineConfig({ const plugin = await import('cypress-mochawesome-reporter/plugin'); plugin.default(on); + const fs = await import('fs'); + on('task', { + deleteFile(filePath) { + if (fs.existsSync(filePath)) { + fs.unlinkSync(filePath); + return true; + } + return false; + }, + }); + return config; }, viewportWidth: 1280, diff --git a/src/components/common/VnInputDate.vue b/src/components/common/VnInputDate.vue index 73c825e1e..1f4705faa 100644 --- a/src/components/common/VnInputDate.vue +++ b/src/components/common/VnInputDate.vue @@ -107,6 +107,7 @@ const manageDate = (date) => { @click="isPopupOpen = !isPopupOpen" @keydown="isPopupOpen = false" hide-bottom-space + :data-cy="$attrs.dataCy ?? $attrs.label + '_inputDate'" >