Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
AlitaBernachot committed Feb 24, 2025
1 parent c05eb18 commit ed39bda
Show file tree
Hide file tree
Showing 6 changed files with 2,389 additions and 1,092 deletions.
12 changes: 12 additions & 0 deletions apps/datahub-e2e/cypress.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,18 @@ export default defineConfig({
setupNodeEvents(on, config) {
cypressBrowserPermissionsPlugin(on, config)
configureCommonPlugins(on, config)

console.log('Downloads folder:', config['downloadsFolder'])

// Configuration spécifique pour les téléchargements sur CI
on('before:browser:launch', (browser, launchOptions) => {
if (browser.family === 'chromium' && browser.name !== 'electron') {
launchOptions.preferences.default['download'] = {
default_directory: config['downloadsFolder'],
}
}
return launchOptions
})
},
retries: {
experimentalStrategy: 'detect-flake-and-pass-on-threshold',
Expand Down
19 changes: 18 additions & 1 deletion apps/datahub-e2e/src/e2e/datasetDetailPage.cy.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import 'cypress-real-events'
import path from 'path'

beforeEach(() => {
before(() => {
// GEOSERVER stubs
cy.intercept(
'GET',
Expand Down Expand Up @@ -542,6 +542,23 @@ describe('dataset pages', () => {
.find('gn-ui-download-item')
.first()
.click()

const downloadsFolder = Cypress.config('downloadsFolder')

// Afficher le chemin du répertoire de téléchargement
cy.log('Répertoire de téléchargement:', downloadsFolder)

// Lister les fichiers dans le répertoire de téléchargement
cy.exec(`ls -l ${downloadsFolder}`, {
failOnNonZeroExit: false,
}).then((result) => {
if (result.code === 0) {
cy.log('Contenu du répertoire:', result.stdout) // Affiche le contenu du répertoire
} else {
cy.log('Le répertoire est vide ou inaccessible:', result.stderr)
}
})

cy.readFile(path.join('cypress/downloads', 'wfs.csv')).as(
'downloadedFile'
)
Expand Down
12 changes: 12 additions & 0 deletions apps/metadata-editor-e2e/cypress.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,18 @@ export default defineConfig({
setupNodeEvents(on, config) {
cypressBrowserPermissionsPlugin(on, config)
configureCommonPlugins(on, config)

console.log('Downloads folder:', config['downloadsFolder'])

// Configuration spécifique pour les téléchargements sur CI
on('before:browser:launch', (browser, launchOptions) => {
if (browser.family === 'chromium' && browser.name !== 'electron') {
launchOptions.preferences.default['download'] = {
default_directory: config['downloadsFolder'],
}
}
return launchOptions
})
},
retries: {
experimentalStrategy: 'detect-flake-and-pass-on-threshold',
Expand Down
19 changes: 19 additions & 0 deletions migrations.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"migrations": [
{
"version": "20.3.0-beta.1",
"description": "Update ESLint flat config to include .cjs, .mjs, .cts, and .mts files in overrides (if needed)",
"implementation": "./src/migrations/update-20-3-0/add-file-extensions-to-overrides",
"package": "@nx/eslint",
"name": "add-file-extensions-to-overrides"
},
{
"cli": "nx",
"version": "20.3.0-beta.2",
"description": "If workspace includes Module Federation projects, ensure the new @nx/module-federation package is installed.",
"factory": "./src/migrations/update-20-3-0/ensure-nx-module-federation-package",
"package": "@nx/angular",
"name": "ensure-nx-module-federation-package"
}
]
}
Loading

0 comments on commit ed39bda

Please sign in to comment.