Skip to content

E2E test failures with older WP versions #405

@ockham

Description

@ockham

In #404, I tentatively (and temporarily) enabled e2e tests for all WP versions starting with 6.2, which is the minimum version required per the plugin header:

* Requires at least: 6.2

I expected Command Palette tests to fail with 6.2, since the Command Palette was only introduced in 6.3. (I'm addressing that in #404.)

However, Command Palette tests also failed in 6.3, alongside a lot of Field Type tests (tests/e2e/field-type-*.spec.ts).
One error I've seen in the browser console is

Uncaught TypeError: Cannot read properties of undefined (reading 'jsx')

which is due to a missing ReactJSXRuntime dependency. The latter was introduced in WP 6.6; we'll likely need to polyfill it in order to support earlier versions.

(Alternatively, we could bump the minimum required version to WP 6.6.)

Other test failures:

  • 6.3, 6.4, 6.5:
    • tests/e2e/block-testimonial.spec.ts:31:2 › SCF Block > Testimonial › should use testimonial block with fields
    • tests/e2e/block-v3-features.spec.ts:161:2 › SCF Block V3 Features › should validate required fields on publish
    • tests/e2e/command-palette.spec.ts: Multiple errors
  • 6.5, 6.6:
    • tests/e2e/block-testimonial.spec.ts:31:2 › SCF Block > Testimonial › should use testimonial block with fields
    • tests/e2e/block-v3-features.spec.ts:36:2 › SCF Block V3 Features
      • should render v3 block in preview-only mode
      • should update preview when sidebar fields change
      • should save v3 block data correctly
  • 6.5, 6.6, 6.7.:
    • tests/e2e/block-bindings-site-editor.spec.ts:24:2 › Block Bindings in Site Editor › should bind text field to paragraph block in site editor

and more in 6.3 and 6.4.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions