The project has both client app and server site code and once the project is built locally it will put all the built assets both front-end and back-end stuff into build directory and it contains all statics assets client needs to use (all test cases are also included there).
When running the subsequent tests Jest will raise a warning message like below due to duplicated manual mock are existing in multiple directories.
jest-haste-map: duplicate manual mock found:
Module name: fileMock
Duplicate Mock path: /Users/x/x/x/x/src/resources/webapp/static/__mocks__/fileMock.js
This warning is caused by two manual mock files with the same file name.
Jest will use the mock file found in:
/Users/x/x/x/x/src/resources/webapp/static/__mocks__/fileMock.js
Please delete one of the following two files:
/Users/x/x/x/x/build/classes/webapp/static/__mocks__/fileMock.js
/Users/x/x/x/x/src/resources/webapp/static/__mocks__/fileMock.js