I have the following database cleaner strategy
DatabaseCleaner.strategy = :truncation, {:except => %w[roles, users, other_tables]}
It's still cleaning the roles table and I don't have any dependent destroy on the models that role belongs to. This does not look like intended behavior. Other than Role table, data is persistent across.
I'd first make sure to define the array correctly, please check in the console what it evaluates to:
There's (probably) no table called
roles,(with a comma at the end).Correct that to:
because: