If I run the specific scenario, it’s all green.
If I only run the cucumber suite (aka. rake cucumber), it’s all green.
However, if I run the full test suite, (aka. rake), a single scenario fails.
I assume this has something to do with the state of the database and my configuration. I wrote the cucumber scenarios to assume an initially empty database, and I’m building small datasets for the individual scenarios.
I’m using DatabaseCleaner, with the truncation strategy, and my understanding is that this will wipe the db clean. Am I mistaken? Is there data lingering that might have been created when the unit and functional tests ran? Is there a quick way to ensure that cucumber starts clean?
Happy to start posting code and wading into config specifics…
thanks
Head in hands. Deep shame.
I was never actually cleaning the database.
I was setting the strategy but never pulling the trigger.
features/support/env.rb
Before:
After:
Don’t let it happen to you.
Sigh.