-
Notifications
You must be signed in to change notification settings - Fork 79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Datastore Amplify Mock Support #104
Comments
Hey @diegoconcha 👋 thanks for taking the time to file this one as well 🙂 marking as a feature request |
+1 |
1 similar comment
+1 |
+1. I'm surprised that this is not supported. What's the best practice for developing with Datastore locally? If we need to rely on a cloud Dev environment, it's slow and not really cost-effective. What if there are multiple developers working on the same project? Does each of them need to create a cloud environment for their branch? Is this a cost-effective approach? Keen to learn more about this 🙏 |
Any update on this? mocking and testing my DataStore app locally would be very useful |
jest.mock('aws-amplify/datastore', () => ({
DataStore: {
configure: jest.fn()
},
initSchema: jest.fn().mockImplementation((schema) => ({
Update: jest.fn(),
Upstream: jest.fn(),
Message: jest.fn()
})),
DISCARD: {}
})) etc. |
Is this feature request related to a new or existing Amplify category?
No response
Is this related to another service?
Datastore
Describe the feature you'd like to request
My team and I spent a week getting excited about and integrating datastore into our app only to find out when trying to test it locally that it doesn't work with amplify mock so we ended up having to rip it out. This would be an awesome improvement as testing on the cloud is slow especially between deploys.
Describe the solution you'd like
We're approach agnostic as long as amplify mock works with datastore :).
Describe alternatives you've considered
Not using datastore and having to wrangle app state and backend state manually.
Additional context
No response
Is this something that you'd be interested in working on?
Would this feature include a breaking change?
The text was updated successfully, but these errors were encountered: