Skip to content

waitForSyncStorage() doesn't wait for sync storage #45

Description

@josephfusco

tests/e2e/utils/collaborative.ts:222:

await page.waitForFunction(() => {
	return window.wp?.data?.select('core/editor')?.getCurrentPost() !== null;
});

That resolves as soon as the editor has a post, which happens well before the storage provider is wired up. Every collaborative test calling this is racing and passing for the wrong reason. It should be waiting on the provider itself.

Metadata

Metadata

Assignees

Labels

InfrastructureIssues for the repository infrastructure[Type] BugAn existing feature is broken

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions