Skip to content

Commit

Permalink
Relabel metro-file-map default export HasteMap->FileMap, createHasteM…
Browse files Browse the repository at this point in the history
…ap->createFileMap

Summary:
This is an overdue rename since `jest-haste-map` -> `metro-file-map`. Haste is not a central concept of this package - it's a core part of Metro even with Haste disabled. Freeing up the name `HasteMap` in order to rename `ModuleMap` for clarity.

Changelog: Internal

Reviewed By: motiz88

Differential Revision: D45033600

fbshipit-source-id: 7134e847194f6c11e558e89fa1ae1a73670b2190
  • Loading branch information
robhogan authored and facebook-github-bot committed Jul 5, 2023
1 parent a80af0b commit 8240186
Show file tree
Hide file tree
Showing 6 changed files with 108 additions and 105 deletions.
Original file line number Diff line number Diff line change
@@ -1,36 +1,36 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`HasteMap file system changes processing recovery from duplicate module IDs recovers when the most recent duplicate is fixed 1`] = `
exports[`FileMap file system changes processing recovery from duplicate module IDs recovers when the most recent duplicate is fixed 1`] = `
"The name \`Pear\` was looked up in the Haste module map. It cannot be resolved, because there exists several different files, or packages, that provide a module for that particular name and platform. The platform is generic (no extension). You must delete or exclude files until there remains only one of these:
* \`/project/fruits/Pear.js\` (module)
* \`/project/fruits/another/Pear.js\` (module)
"
`;

exports[`HasteMap file system changes processing recovery from duplicate module IDs recovers when the oldest version of the duplicates is fixed 1`] = `
exports[`FileMap file system changes processing recovery from duplicate module IDs recovers when the oldest version of the duplicates is fixed 1`] = `
"The name \`Pear\` was looked up in the Haste module map. It cannot be resolved, because there exists several different files, or packages, that provide a module for that particular name and platform. The platform is generic (no extension). You must delete or exclude files until there remains only one of these:
* \`/project/fruits/Pear.js\` (module)
* \`/project/fruits/another/Pear.js\` (module)
"
`;

exports[`HasteMap tries to crawl using node as a fallback 1`] = `
exports[`FileMap tries to crawl using node as a fallback 1`] = `
"metro-file-map: Watchman crawl failed. Retrying once with node crawler.
Usually this happens when watchman isn't running. Create an empty \`.watchmanconfig\` file in your project's root folder or initialize a git or hg repository in your project.
Error: watchman error"
`;

exports[`HasteMap warns on duplicate mock files 1`] = `
exports[`FileMap warns on duplicate mock files 1`] = `
"metro-file-map: duplicate manual mock found: subdir/Blueberry
The following files share their name; please delete one of them:
* <rootDir>/fruits1/__mocks__/subdir/Blueberry.js
* <rootDir>/fruits2/__mocks__/subdir/Blueberry.js
"
`;
exports[`HasteMap warns on duplicate module ids 1`] = `
exports[`FileMap warns on duplicate module ids 1`] = `
"metro-file-map: Haste module naming collision: Strawberry
The following files share their name; please adjust your hasteImpl:
* <rootDir>/fruits/Strawberry.js
Expand Down
Loading

0 comments on commit 8240186

Please sign in to comment.