Fix Setup.php file-scope test
authorBrad Jorsch <bjorsch@wikimedia.org>
Thu, 4 Oct 2018 20:34:28 +0000 (16:34 -0400)
committerBrad Jorsch <bjorsch@wikimedia.org>
Thu, 4 Oct 2018 20:40:15 +0000 (16:40 -0400)
commit4d74c8bf74f0a7bdb65ecc8802726c8408e583f8
tree080b053d23ee3e7bd50fe0c81d15bebe2ffc17d7
parenta3c780d08cc522b30c18fcfb77eaa4d2a88a1890
Fix Setup.php file-scope test

Way back in r8196, a test was added to assert that Setup.php is being
included at file scope.[1] That test was broken when I633a6ff23 moved the
inclusion of DefaultSettings.php into Setup.php itself.

This fixes the test by having it directly set a variable and see if that
variable is a global. Yes, there's several ways to bypass it, but we're
just trying to avoid accidents here rather than trying to be foolproof.

[1]: Or really, in the same scope as DefaultSettings.php. But it
intended to be checking for file scope.

Change-Id: I9b5f15bf01c2903e8d44d85c54465d90c047cb51
includes/Setup.php