Dear everyone,
our current PHPUnit setup uses temporary tables for MySQL; tables that
are visible only to the current connection.
When trying to test core objects (e.g.: BackupDumper) that spawn a
separate database connection, this causes trouble, as this new
database connection does not see the temporary tables of the first
connection.
How to test such objects?
Possible ways around might be to
(i) modify the tested object,
(ii) modify the PHPUnit setup,
(iii) force a special load balancer for testing, or
(iv) completely mock the database for tests (when testing non backend objects).
Any suggestions / preferences?
Kind regards,
Christian
P.S.: As this might affect the discussion: A different incarnation of
the same problem is that our PHPUnit test suite currently does not run
on a MySQL cluster (without passing --use-normal-tables).
--
---- quelltextlich e.U. ---- \\ ---- Christian Aistleitner ----
Companies' registry: 360296y in Linz
Christian Aistleitner
Gruendbergstrasze 65a Email: christian(a)quelltextlich.at
4040 Linz, Austria Phone: +43 732 / 26 95 63
Fax: +43 732 / 26 95 63
Homepage:
http://quelltextlich.at/
---------------------------------------------------------------