[Cypress] Disable CI Citoid flaky test

I'm still not sure what causes this to fail in CI locally they
are running fine. In the CI it seems from the recordings, that
Citoid is not loaded when these tests are executed.

Bug: T366383
Change-Id: Iee9e4dd04e08fd3ddfa77409d037ec80f84ead3e
This commit is contained in:
WMDE-Fisch 2024-06-03 11:35:52 +02:00
parent 85fddfb1e4
commit d05b738a29
3 changed files with 21 additions and 0 deletions

13
package-lock.json generated
View file

@ -7,6 +7,7 @@
"": { "": {
"name": "Cite", "name": "Cite",
"devDependencies": { "devDependencies": {
"@cypress/skip-test": "^2.6.1",
"cypress": "^13.8.1", "cypress": "^13.8.1",
"eslint-config-wikimedia": "0.27.0", "eslint-config-wikimedia": "0.27.0",
"eslint-plugin-cypress": "^2.15.1", "eslint-plugin-cypress": "^2.15.1",
@ -420,6 +421,12 @@
"uuid": "dist/bin/uuid" "uuid": "dist/bin/uuid"
} }
}, },
"node_modules/@cypress/skip-test": {
"version": "2.6.1",
"resolved": "https://registry.npmjs.org/@cypress/skip-test/-/skip-test-2.6.1.tgz",
"integrity": "sha512-X+ibefBiuOmC5gKG91wRIT0/OqXeETYvu7zXktjZ3yLeO186Y8ia0K7/gQUpAwuUi28DuqMd1+7tBQVtPkzbPA==",
"dev": true
},
"node_modules/@cypress/xvfb": { "node_modules/@cypress/xvfb": {
"version": "1.2.4", "version": "1.2.4",
"resolved": "https://registry.npmjs.org/@cypress/xvfb/-/xvfb-1.2.4.tgz", "resolved": "https://registry.npmjs.org/@cypress/xvfb/-/xvfb-1.2.4.tgz",
@ -7219,6 +7226,12 @@
} }
} }
}, },
"@cypress/skip-test": {
"version": "2.6.1",
"resolved": "https://registry.npmjs.org/@cypress/skip-test/-/skip-test-2.6.1.tgz",
"integrity": "sha512-X+ibefBiuOmC5gKG91wRIT0/OqXeETYvu7zXktjZ3yLeO186Y8ia0K7/gQUpAwuUi28DuqMd1+7tBQVtPkzbPA==",
"dev": true
},
"@cypress/xvfb": { "@cypress/xvfb": {
"version": "1.2.4", "version": "1.2.4",
"resolved": "https://registry.npmjs.org/@cypress/xvfb/-/xvfb-1.2.4.tgz", "resolved": "https://registry.npmjs.org/@cypress/xvfb/-/xvfb-1.2.4.tgz",

View file

@ -10,6 +10,7 @@
"lint:fix": "grunt test --fix" "lint:fix": "grunt test --fix"
}, },
"devDependencies": { "devDependencies": {
"@cypress/skip-test": "^2.6.1",
"cypress": "^13.8.1", "cypress": "^13.8.1",
"eslint-config-wikimedia": "0.27.0", "eslint-config-wikimedia": "0.27.0",
"eslint-plugin-cypress": "^2.15.1", "eslint-plugin-cypress": "^2.15.1",

View file

@ -1,3 +1,4 @@
require( '@cypress/skip-test/support' );
import * as helpers from './../../utils/functions.helper.js'; import * as helpers from './../../utils/functions.helper.js';
const refText1 = 'This is citation #1 for reference #1 and #2'; const refText1 = 'This is citation #1 for reference #1 and #2';
@ -38,6 +39,9 @@ describe( 'Re-using refs in Visual Editor', () => {
} ); } );
it( 'should display re-used reference in article with correct footnote number and notification in context dialog', () => { it( 'should display re-used reference in article with correct footnote number and notification in context dialog', () => {
// TODO: Renable test with Citoid when they're stable in CI
cy.skipOn( usesCitoid );
// Currently there are 3 refs in the article // Currently there are 3 refs in the article
helpers.getRefsFromArticleSection().should( 'have.length', 3 ); helpers.getRefsFromArticleSection().should( 'have.length', 3 );
@ -82,6 +86,9 @@ describe( 'Re-using refs in Visual Editor', () => {
} ); } );
it( 'should display correct ref content and name attribute for re-used ref with existing name attribute', () => { it( 'should display correct ref content and name attribute for re-used ref with existing name attribute', () => {
// TODO: Renable test with Citoid when they're stable in CI
cy.skipOn( usesCitoid );
// Place cursor next to ref #1 in order to add re-used ref next to it // Place cursor next to ref #1 in order to add re-used ref next to it
cy.contains( '.mw-reflink-text', '[1]' ).first().type( '{rightarrow}' ); cy.contains( '.mw-reflink-text', '[1]' ).first().type( '{rightarrow}' );