diff --git a/.sauce/config.yml b/.sauce/config.yml index 6b465d7be3..5d836840ea 100644 --- a/.sauce/config.yml +++ b/.sauce/config.yml @@ -24,13 +24,13 @@ suites: - "Tests/IntegrationTests/Fixtures/*/*.e2e.js" platformName: "Windows 10" screenResolution: "1280x1024" - - name: "Tests in Firefox on MacOS" - # todo use chrome here and fix ci https://github.com/neos/neos-ui/issues/3591 - browserName: "firefox" - src: - - "Tests/IntegrationTests/Fixtures/*/*.e2e.js" - platformName: "macOS 13" - screenResolution: "1440x900" + # todo use chrome here and fix ci https://github.com/neos/neos-ui/issues/3591 (but even firefox fails in ci) + # - name: "Tests in Firefox on MacOS" + # browserName: "firefox" + # src: + # - "Tests/IntegrationTests/Fixtures/*/*.e2e.js" + # platformName: "macOS 13" + # screenResolution: "1440x900" npm: dependencies: - testcafe-react-selectors diff --git a/Tests/IntegrationTests/Fixtures/1Dimension/syncing.e2e.js b/Tests/IntegrationTests/Fixtures/1Dimension/syncing.e2e.js index ff4166aa10..b2db46a047 100644 --- a/Tests/IntegrationTests/Fixtures/1Dimension/syncing.e2e.js +++ b/Tests/IntegrationTests/Fixtures/1Dimension/syncing.e2e.js @@ -11,6 +11,8 @@ import { fixture`Syncing` .afterEach(() => checkPropTypes()); +fixture.skip`TODO Tests are flaky and create catchup errors rendering following tests also kaput: https://github.com/neos/neos-ui/pull/3769#pullrequestreview-2332466270`; + const contentIframeSelector = Selector('[name="neos-content-main"]', {timeout: 2000}); test('Syncing: Create a conflict state between two editors and choose "Discard all" as a resolution strategy during rebase', async t => { diff --git a/Tests/IntegrationTests/Fixtures/2Dimension/switchingSites.e2e.js b/Tests/IntegrationTests/Fixtures/2Dimension/switchingSites.e2e.js index f323f54eb2..2f9418b416 100644 --- a/Tests/IntegrationTests/Fixtures/2Dimension/switchingSites.e2e.js +++ b/Tests/IntegrationTests/Fixtures/2Dimension/switchingSites.e2e.js @@ -20,7 +20,7 @@ test('Switching from Neos.Test.OneDimension to Neos.Test.TwoDimensions and back' subSection('Switch to Neos.Test.TwoDimensions via main menu'); await t.click(Selector('#neos-MenuToggler')); - await t.click(Selector('[href*="twodimensions"]')); + await t.click(Selector('[href*="twodimensions"] button')); await t.expect(getUrl()).contains('twodimensions.localhost', 'Switch to Neos.Test.TwoDimensions was successful'); @@ -28,7 +28,7 @@ test('Switching from Neos.Test.OneDimension to Neos.Test.TwoDimensions and back' await waitForReact(30000); await Page.goToPage('Home'); await t.click(Selector('#neos-MenuToggler')); - await t.click(Selector('[href*="onedimension"]')); + await t.click(Selector('[href*="onedimension"] button')); await t.expect(getUrl()).contains('onedimension.localhost', 'Switch to Neos.Test.OneDimension was successful'); }); @@ -45,7 +45,7 @@ test('Switching from Neos.Test.TwoDimensions to Neos.Test.OneDimension and back' subSection('Switch to Neos.Test.OneDimension via main menu'); await t.click(Selector('#neos-MenuToggler')); - await t.click(Selector('[href*="onedimension"]')); + await t.click(Selector('[href*="onedimension"] button')); await t.expect(getUrl()).contains('onedimension.localhost', 'Switch to Neos.Test.OneDimension was successful'); @@ -53,7 +53,7 @@ test('Switching from Neos.Test.TwoDimensions to Neos.Test.OneDimension and back' await waitForReact(30000); await Page.goToPage('Home'); await t.click(Selector('#neos-MenuToggler')); - await t.click(Selector('[href*="twodimensions"]')); + await t.click(Selector('[href*="twodimensions"] button')); await t.expect(getUrl()).contains('twodimensions.localhost', 'Switch to Neos.Test.TwoDimensions was successful'); }); diff --git a/packages/neos-ui-ckeditor5-bindings/src/plugins/neosPlaceholder.js b/packages/neos-ui-ckeditor5-bindings/src/plugins/neosPlaceholder.js deleted file mode 100644 index 721fe8858f..0000000000 --- a/packages/neos-ui-ckeditor5-bindings/src/plugins/neosPlaceholder.js +++ /dev/null @@ -1,75 +0,0 @@ -import Plugin from '@ckeditor/ckeditor5-core/src/plugin'; -import {stripTags} from '@neos-project/utils-helpers'; -import './neosPlaceholder.vanilla-css'; - -// If the data is "empty" (BR, P) or the placeholder then return an empty string. -// Otherwise return the original data -const htmlIsEmptyish = data => { - if (!data) { - return true; - } - - if (data.length > 20) { - return false; - } - const value = data.replace(/[\n|\t|\u200b]*/g, '').toLowerCase().trim(); - const a = ( - !value || - value === '
' || - value === ' ' || - value === '

 

' || - value === '

 

' || - value === '


' || - value === ' ' || - value === ' 
' || - value === '
' || - value.match(/^<([a-z0-9]+)>
<\/\1>$/) - ); - return a; -}; - -export default class NeosPlaceholder extends Plugin { - static get pluginName() { - return 'NeosPlaceholder'; - } - - getPlaceholder() { - return stripTags(this.editor.config.get('neosPlaceholder')); - } - - addPlaceholder() { - this.editor.editing.view.change(writer => { - writer.setAttribute('data-neos-placeholder', this.getPlaceholder(), this.editor.editing.view.document.getRoot()); - }); - } - - removePlaceholder() { - this.editor.editing.view.change(writer => { - writer.removeAttribute('data-neos-placeholder', this.editor.editing.view.document.getRoot()); - }); - } - - updatePlaceholder() { - if (htmlIsEmptyish(this.editor.getData({trim: 'none'})) && !this.editor.ui.focusTracker.isFocused) { - this.addPlaceholder(); - } else { - this.removePlaceholder(); - } - } - - init() { - if (this.editor.config.get('neosPlaceholder')) { - this.updatePlaceholder(); - - const {model} = this.editor.data; - - model.on('applyOperation', () => { - this.updatePlaceholder(); - return true; - }); - this.editor.ui.focusTracker.on('change:isFocused', () => { - this.updatePlaceholder(); - }); - } - } -}