amplify
amplify copied to clipboard
[Tests] Mock data for Lob API
Context
Lob is used to store addresses where letters go. While there is an address verification mechanism, there are edge cases such as satellites, non-residential, and POs to consider
Files to have open: lob.js, https://github.com/ProgramEquity/amplify/blob/main/server/tests/integration/lob.test.js
Tasks:
- [ ] Create a mocks model file for addresses
- Copilot prompt while lob.jest.js open: where would I create mock files
- [ ] Create an array of addresses across edge cases
- Copilot prompt:
- How can I use Jest to mock API calls in my tests?
- In Lob.js Highlight lines 256-281: Mock data for edge cases
- In Lob.test.js Highlight lines 264-272: Mock data for test
- Copilot prompt: