[Phpmyadmin-devel] PHPUnit tests and backupGlobals

Madhura Jayaratne madhura.cj at gmail.com
Thu May 30 14:06:20 CEST 2013


On Thu, May 30, 2013 at 9:14 AM, Ayush Chaudhary <ayushchd at gmail.com> wrote:

> Hi,
>
> On Wednesday, 29 May 2013 at 11:51 PM, Madhura Jayaratne wrote:
>
> Hi all,
>
> At the test suit level, backupGlobals directive is set to false preventing
> PHPUnit from backing up and restoring globals for every test. I was
> wondering why this is set like that.
>
> Different tests have or need different global settings. So I think this is
> to prevent the global settings of different tests from interfering with
> each other.
>
> Thanks,
> Ayush
>
> If I understand correctly, when backupGlobals is set to true, before each
test globals are backed up and restored after test execution. So any
changes done to globals by the test do not propagate to the next test.
Ideally each test should setup variables required for it and should not
depend on other tests to set up variable values.

-- 
Thanks and Regards,

Madhura Jayaratne
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.phpmyadmin.net/pipermail/developers/attachments/20130530/d74b4c4e/attachment.html>


More information about the Developers mailing list