Skip to content

Commit

Permalink
chore: rename integration-tests -> e2e
Browse files Browse the repository at this point in the history
  • Loading branch information
thymikee committed May 27, 2018
1 parent 266e7dc commit e9326b6
Show file tree
Hide file tree
Showing 514 changed files with 36 additions and 41 deletions.
13 changes: 5 additions & 8 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ module.exports = {
},
},
{
files: ['scripts/**/*', 'integration-tests/**/*'],
files: ['scripts/**/*', 'e2e/**/*'],
rules: {
'babel/func-params-comma-dangle': 0,
},
Expand All @@ -56,14 +56,11 @@ module.exports = {
},
},
{
excludedFiles: [
'integration-tests/__tests__/**/*',
'website/versioned_docs/**/*.md',
],
excludedFiles: ['e2e/__tests__/**/*', 'website/versioned_docs/**/*.md'],
files: [
'examples/**/*',
'scripts/**/*',
'integration-tests/*/**/*',
'e2e/*/**/*',
'website/*/**/*',
'eslintImportResolver.js',
],
Expand All @@ -81,7 +78,7 @@ module.exports = {
},
{
files: [
'integration-tests/__tests__/**/*',
'e2e/__tests__/**/*',
'packages/babel-jest/**/*.test.js',
'packages/babel-plugin-jest-hoist/**/*.test.js',
'packages/babel-preset-jest/**/*.test.js',
Expand All @@ -103,7 +100,7 @@ module.exports = {
files: [
'website/**',
'**/__tests__/**',
'integration-tests/**',
'e2e/**',
'**/pretty-format/perf/**',
],
rules: {
Expand Down
10 changes: 5 additions & 5 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@
*~
/examples/*/node_modules/

/integration-tests/*/node_modules
!/integration-tests/presets/json/node_modules
!/integration-tests/presets/js/node_modules
/integration-tests/transform/*/coverage
/integration-tests/transform/*/node_modules
/e2e/*/node_modules
!/e2e/presets/json/node_modules
!/e2e/presets/js/node_modules
/e2e/transform/*/coverage
/e2e/transform/*/node_modules

/node_modules

Expand Down
4 changes: 2 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@
### Chore & Maintenance

* `[jest-config]` Allow `<rootDir>` to be used with `collectCoverageFrom` ([#5524](https://github.com/facebook/jest/pull/5524))
* `[filenames]` Standardize files names in "integration-tests" folder ([#5513](https://github.com/facebook/jest/pull/5513))
* `[filenames]` Standardize files names in "e2e" folder ([#5513](https://github.com/facebook/jest/pull/5513))

## jest 22.2.2

Expand Down Expand Up @@ -295,7 +295,7 @@

### Chore & Maintenance

* `[filenames]` Standardize folder names under `integration-tests/` ([#5298](https://github.com/facebook/jest/pull/5298))
* `[filenames]` Standardize folder names under `e2e/` ([#5298](https://github.com/facebook/jest/pull/5298))

## jest 22.0.6

Expand Down
2 changes: 1 addition & 1 deletion docs/SnapshotTesting.md
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ Yes, all snapshot files should be committed alongside the modules they are cover

### Does snapshot testing only work with React components?

[React](TutorialReact.md) and [React Native](TutorialReactNative.md) components are a good use case for snapshot testing. However, snapshots can capture any serializable value and should be used anytime the goal is testing whether the output is correct. The Jest repository contains many examples of testing the output of Jest itself, the output of Jest's assertion library as well as log messages from various parts of the Jest codebase. See an example of [snapshotting CLI output](https://github.com/facebook/jest/blob/master/integration-tests/__tests__/console.test.js) in the Jest repo.
[React](TutorialReact.md) and [React Native](TutorialReactNative.md) components are a good use case for snapshot testing. However, snapshots can capture any serializable value and should be used anytime the goal is testing whether the output is correct. The Jest repository contains many examples of testing the output of Jest itself, the output of Jest's assertion library as well as log messages from various parts of the Jest codebase. See an example of [snapshotting CLI output](https://github.com/facebook/jest/blob/master/e2e/__tests__/console.test.js) in the Jest repo.

### What's the difference between snapshot testing and visual regression testing?

Expand Down
File renamed without changes.
8 changes: 8 additions & 0 deletions e2e/__tests__/__snapshots__/list_tests.test.js.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`--listTests flag causes tests to be printed in different lines 1`] = `
"/MOCK_ABOLUTE_PATH/e2e/list-tests/__tests__/dummy.test.js
/MOCK_ABOLUTE_PATH/e2e/list-tests/__tests__/other.test.js"
`;

exports[`--listTests flag causes tests to be printed out as JSON when using the --json flag 1`] = `"[\\"/MOCK_ABOLUTE_PATH/e2e/list-tests/__tests__/dummy.test.js\\",\\"/MOCK_ABOLUTE_PATH/e2e/list-tests/__tests__/other.test.js\\"]"`;
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,7 @@ test('traverses directory tree up until it finds jest.config', () => {
);

// Snapshot the console.loged `process.cwd()` and make sure it stays the same
expect(
stdout.replace(/^\W+(.*)integration-tests/gm, '<<REPLACED>>'),
).toMatchSnapshot();
expect(stdout.replace(/^\W+(.*)e2e/gm, '<<REPLACED>>')).toMatchSnapshot();

const {rest, summary} = extractSummary(stderr);
expect(status).toBe(0);
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ describe('JSON Reporter', () => {
const outputFileName = 'sum.result.json';
const outputFilePath = path.join(
process.cwd(),
'integration-tests/json-reporter/',
'e2e/json-reporter/',
outputFileName,
);

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit e9326b6

Please sign in to comment.