mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2025-10-16 12:05:38 +00:00
Build/Test Tools: Add basic e2e coverage for Gutenberg.
Add some minimal e2e test coverage to install and activate the Gutenberg plugin. This will catch naming collisions between Core and Gutenberg and help avoid crashing WordPress installations that run the stable version of the Gutenberg plugin on top of Core trunk. Props costdev. Fixes #57197. git-svn-id: https://develop.svn.wordpress.org/trunk@54913 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
0fa641caca
commit
bb2f8a6d4f
24
tests/e2e/specs/gutenberg-plugin.test.js
Normal file
24
tests/e2e/specs/gutenberg-plugin.test.js
Normal file
@ -0,0 +1,24 @@
|
||||
import {
|
||||
activatePlugin,
|
||||
deactivatePlugin,
|
||||
installPlugin,
|
||||
uninstallPlugin,
|
||||
} from '@wordpress/e2e-test-utils';
|
||||
|
||||
describe( 'Gutenberg plugin', () => {
|
||||
beforeAll( async () => {
|
||||
await installPlugin( 'gutenberg' );
|
||||
} );
|
||||
|
||||
afterAll( async () => {
|
||||
await uninstallPlugin( 'gutenberg' );
|
||||
} );
|
||||
|
||||
it( 'Activate the Gutenberg plugin', async () => {
|
||||
await activatePlugin( 'gutenberg' );
|
||||
// If plugin activation fails, it will time out and throw an error,
|
||||
// since the activatePlugin helper is looking for a `.deactivate` link
|
||||
// which is only there if activation succeeds.
|
||||
await deactivatePlugin( 'gutenberg' );
|
||||
} );
|
||||
} );
|
||||
Loading…
Reference in New Issue
Block a user