Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reorganisation of e2e tests #17990

Merged
merged 5 commits into from
Oct 17, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/e2e-tests/jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@ module.exports = {
testPathIgnorePatterns: [
'/node_modules/',
'/wordpress/',
'e2e-tests/specs/performance.test.js',
'e2e-tests/specs/performance/',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

],
};
2 changes: 1 addition & 1 deletion packages/e2e-tests/jest.performance.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
module.exports = {
...require( '@wordpress/scripts/config/jest-e2e.config' ),
testMatch: [
'**/performance.test.js',
'**/performance/*.test.js',
],
setupFiles: [
'<rootDir>/config/gutenberg-phase.js',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ describe( 'Classic', () => {
// Wait for media modal to appear and upload image.
await page.waitForSelector( '.media-modal input[type=file]' );
const inputElement = await page.$( '.media-modal input[type=file]' );
const testImagePath = path.join( __dirname, '..', '..', 'assets', '10x10_e2e_test_image_z9T8jK.png' );
const testImagePath = path.join( __dirname, '..', '..', '..', 'assets', '10x10_e2e_test_image_z9T8jK.png' );
const filename = uuid();
const tmpFileName = path.join( os.tmpdir(), filename + '.png' );
fs.copyFileSync( testImagePath, tmpFileName );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ describe( 'adding inline tokens', () => {
// Wait for media modal to appear and upload image.
await page.waitForSelector( '.media-modal input[type=file]' );
const inputElement = await page.$( '.media-modal input[type=file]' );
const testImagePath = path.join( __dirname, '..', 'assets', '10x10_e2e_test_image_z9T8jK.png' );
const testImagePath = path.join( __dirname, '..', '..', '..', 'assets', '10x10_e2e_test_image_z9T8jK.png' );
const filename = uuid();
const tmpFileName = path.join( os.tmpdir(), filename + '.png' );
fs.copyFileSync( testImagePath, tmpFileName );
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ describe( 'Managing reusable blocks', () => {
await importButton.click();

// Select the file to upload
const testReusableBlockFile = path.join( __dirname, '..', 'assets', 'greeting-reusable-block.json' );
const testReusableBlockFile = path.join( __dirname, '..', '..', '..', 'assets', 'greeting-reusable-block.json' );
const input = await page.$( '.list-reusable-blocks-import-form input' );
await input.uploadFile( testReusableBlockFile );

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ import {
getAvailableBlockFixturesBasenames,
getBlockFixtureHTML,
getBlockFixtureParsedJSON,
} from '../fixtures/';
import { EXPECTED_TRANSFORMS } from '../fixtures/block-transforms.js';
} from '../../fixtures/';
import { EXPECTED_TRANSFORMS } from '../../fixtures/block-transforms.js';

/*
* Returns true if the fileBase refers to a fixture of a block
Expand Down