[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Deciding on a default company setup for BDD tests

David G <..hidden..> wrote:
    > This was sort of my point too, I don't think it is worth the extra effort to
    > try and clean up the DB so tests can be re-run. Just drop the db and re-clone
    > it before rerunning the test. You don't want to drop it after running the
    > tests incase you need to manually verify something. hence the suggestion to
    > use a known naming scheme so it is obvious what a db is for.

It would be ideal if we could run the tests in a transaction, and then just
roll it back.  That's what Rails and Django do.

I wonder if we could use some other postgresql magic here... for instance,
maybe the new feature that makes the database hide anything that isn't
between the valid time stamps. (I learnt of this at PGcon, I can't find the
feature at the moment).

If not, maybe:
   CREATE DATABASE newdb WITH TEMPLATE originaldb OWNER dbuser;

would make it nice and fast to run between test cases... getting the test
cases to run really fast, is pretty important, and I don't think going behind
the applications' back to clean it is unreasaonable.

]               Never tell me the odds!                 | ipv6 mesh networks [
]   Michael Richardson, Sandelman Software Works        | network architect  [
]     ..hidden..  http://www.sandelman.ca/        |   ruby on rails    [

Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
Ledger-smb-devel mailing list