Now that spurious commits were removed in document module,
the test would not run properly anymore.
We do need special care with transactions when we test the
FTP layer because operations on the virtual FS are done
in their own transaction, and immediately committed.
In order for test code and FTP operations to be able
to see each other, the transactions need to be synchronized.
The current test transaction needs to be rolled back
or committed after reach FTP operation so it can "see" the
latest changes in the database. Similarly, we must force
a commit of the test transaction whenever we want the
FTP layer to be able to see its effects.
bzr revid: odo@openerp.com-20111130120244-3m15sxdx1x5x1q1x
(Otherwise changes happening on one cursor are not visible to the other one.)
Normally, as those yaml files commit(), they sould be inside demo data
instead of tests. But really we want to test a completely initialized
database, not being executed while the database is being initialized
(as the demo data are). This is just a matter of convention as the
tests are only executed when you also install demo data.
bzr revid: vmt@openerp.com-20111007091737-2dzocv2rgm2gfbi2
At trunk-xrg, the FTP daemon is only started *after* the db is loaded,
which means that it will not be available for tests on a server upgrade.
(still, tests can be performed through the base_module_record's importer)
Anyway, it is not wise to block the server startup if FTP doesn't
respond.
bzr revid: p_christ@hol.gr-20100713103016-33gu4o7yvkn7hmnd