testdouble / cypress-rails

Helps you write Cypress tests of your Rails app
Other
321 stars 48 forks source link

Rails 7 MongoDB No Rollback of transactions? #154

Closed perkins2099 closed 1 year ago

perkins2099 commented 1 year ago

Trying to get this gem to work with mongodb.

The data isn't being rolled back between tests and will persist until cypress is restarted and reseeds. Also I do not see documentation on how to configure it or if there might be any differences for mongodb?

searls commented 1 year ago

Hello! Unfortunately, I'm not sure whether there's any relationship between ActiveRecord transactions and whatever mongo wrapper you're using. I imagine you'd probably have to roll your own using a test-specific controller endpoint.

You might have more luck with @shakacode's https://github.com/shakacode/cypress-on-rails gem, as that one is a little more robust in its configuration/customization, I believe