At my current project, the other developer prefers mysql and uses only that,
I prefer postgresql and use it mostly (but sometimes I test on mysql). Already
on 2 occasions, I had tests fail, (on postgresql) that passed on mysql.
- we had an issue where a schema.db was incorrectly processed by
mysql upon rake test:prepare (this worked correctly in postgresql).
We switched to RAKE_ENV=test rake db:create/migrate/seed for
- postgresql checks more rigorously on certain cases of uniqueness
of the primary key (I think that was writing a rake db:seed with a fixed
low value id (16 actually) that was saved later on by the regular create
tests … mysql happily created a second a row with that id? postgresql
And this is just a fairly “simple” project smaller than 1 person year …
When you get to more complex projects, the number of issues will
certainly increase. What I generally do, is also test on mysql. In
general, I find keeping up multi-platform compatibility a good
measure to see if I keep to “standard/future proof” implementations
(unless I really need a specialized feature of postgresql).
So yes, I think it is relevant to do some regular development/testing
runs with exactly the same database version as in production (and
even within postgresql, versions can matter since certain not really
valid constructs get more rigorously tested and may throw an
exception with newer versions).