jenkins-bot has submitted this change and it was merged.

Change subject: Call parent::setUp() in DiffHistoryBlobTest before marking 
skipped tests
......................................................................


Call parent::setUp() in DiffHistoryBlobTest before marking skipped tests

Jenkins skips these tests because xdiff is unavailable. The tests get
marked as skipped, out of order and before the error reporting setup.

Things are left in an inconsistent state when running *all* the tests together,
and interferes with later error handling (including PHPUnit_Framework_Error)
in other tests.

The gate-and-submit and other jobs are split into multiple jobs,
and for some reason does not trigger this issue.

This will probably fix bug 57488.

Bug: 57488
Change-Id: Ie1a213e912b5858b43956fc35cf00226636f2093
---
M tests/phpunit/includes/DiffHistoryBlobTest.php
1 file changed, 3 insertions(+), 1 deletion(-)

Approvals:
  Hoo man: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/tests/phpunit/includes/DiffHistoryBlobTest.php 
b/tests/phpunit/includes/DiffHistoryBlobTest.php
index 76a9a10..0b04c6e 100644
--- a/tests/phpunit/includes/DiffHistoryBlobTest.php
+++ b/tests/phpunit/includes/DiffHistoryBlobTest.php
@@ -1,7 +1,10 @@
 <?php
 
 class DiffHistoryBlobTest extends MediaWikiTestCase {
+
        protected function setUp() {
+               parent::setUp();
+
                if ( !extension_loaded( 'xdiff' ) ) {
                        $this->markTestSkipped( 'The xdiff extension is not 
available' );
 
@@ -17,7 +20,6 @@
 
                        return;
                }
-               parent::setUp();
        }
 
        /**

-- 
To view, visit https://gerrit.wikimedia.org/r/97352
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ie1a213e912b5858b43956fc35cf00226636f2093
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Aude <[email protected]>
Gerrit-Reviewer: Bartosz DziewoƄski <[email protected]>
Gerrit-Reviewer: Daniel Kinzler <[email protected]>
Gerrit-Reviewer: Hashar <[email protected]>
Gerrit-Reviewer: Hoo man <[email protected]>
Gerrit-Reviewer: Legoktm <[email protected]>
Gerrit-Reviewer: jenkins-bot

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to