Use common doctest_dropdb

review2151002
Avoid unnecessary browsing in get_amount().

review2321002
issue3556
Do not copy invoices one by one.

Do not copy invoices one by one because the new copy action on xxx2Many fields
already takes care of this.

review2331002
Merge