Open BitcoinZavior opened 2 years ago
Step 1 and Step 2 done.
A lot more test cases now pass:
A lot of test cases fail because expected, address, xpub or specific info does not match the hardcoded data in test cases:
The test cases failing are because the test cases expect specific mnemonics in the .env file. If the same info info is not provided in the .env file then test cases will need to be re written.
Hey. The tests that cover the wallet libraries were ported from BlueWallet. I don't have the env vars either. You will have to replace them with new seeds and addresses if you want the tests to pass.
@tanx if we use new seeds in .env then we will need to update all the test cases with new addresses and other derived data isn't it? Or am I missing something?
All test cases don't pass.
To Replicate:
npm run
npm run test
ornpm run test:integration
andnpm run test:unit
results in the following:This is because of env file is not being read to provide the the mnemonics.
Issue and suggested Solution:
dotenv
dev dependency is required or an env variables file to be read viaprocess.env.
Once this dev dependency is added it will need to configured in jest or in
photon-lib/__tests__/setup.js
There could be some other instances where specific values are required.
Also the hardcoded peers might need to be updated as well in case this is an issue.
If all the test cases were passing before then It would be great if someone who has worked on the project before can share a env file which works with the test cases.