Angular - e2e - protractor: fake data

9 views
Skip to first unread message

Agustin Viñao

unread,
Apr 18, 2018, 9:17:49 AM4/18/18
to Angular and AngularJS discussion
Hi all,

Im trying to resolve the best way to do my e2e tests in terms of fake data. I been working with ember a few times and I found mirage as a grate tool for mocking data and testing.

I saw the content in the styleguides where it explains unit tests are the best place for testing mainly because e2e tests may need more maintenance that unit tests, but the value of e2e testing can't be push aside. 

I haven't found a good way to do it in angular (5.x) and it should be good if we can share how others have resolve this problem and try to unify efforts on this.

My personal approach for now is to run my e2e tests in a different environment (test env of course) and use a specific API endpoint with fixed data. One of the problems with this approach is I need to "reset" my "api db" to a specific state each time  I want to run my e2e suite tests.

thanks 
Reply all
Reply to author
Forward
0 new messages