I inherited a Rails project where the (SQLite) Dev and Test databases are the same, as in the database.yml file.
Are there any advantages to this? Why would anyone do this?
The test database will get overwritten by the tests normally (unless you use transactional fixtures). If test and development databases are the same, your data will be erased every time you run your test suite. Development data may interfere with the test suite and make it unrealiable.
I would cleary consider this a design mistake. There is no reason, you should ever do this. Even the database.yml in a freshly created rails app states:
# Warning: The database defined as "test" will be erased and
# re-generated from your development database when you run "rake".
# Do not set this db to the same as development or production.
There are no advantages to this. There are disdvantages. test and development or production databases are supposed to be different. A lot of people leave test and development settings the same and it's not that big of a problem since the most important one is the production database. That's the reason i can think of that made the previous dev. on the project do that. It should not be like that though.