Mwjames has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/77501


Change subject: Add test to ChangeObserverTest
......................................................................

Add test to ChangeObserverTest

Change-Id: I55fa837998b939c4f04e24a4b1d4e71c630ee6f0
---
M tests/phpunit/MockChangeObserver.php
M tests/phpunit/includes/ChangeObserverTest.php
2 files changed, 33 insertions(+), 1 deletion(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/SemanticMediaWiki 
refs/changes/01/77501/1

diff --git a/tests/phpunit/MockChangeObserver.php 
b/tests/phpunit/MockChangeObserver.php
index 3989af8..51015ae 100644
--- a/tests/phpunit/MockChangeObserver.php
+++ b/tests/phpunit/MockChangeObserver.php
@@ -55,7 +55,7 @@
         *
         * @since 1.9
         */
-       public function setNotifier( $notifier ) {
+       private function setNotifier( $notifier ) {
                $this->notifier = method_exists( get_parent_class( $this ), 
$notifier ) ? $notifier : null;
        }
 
diff --git a/tests/phpunit/includes/ChangeObserverTest.php 
b/tests/phpunit/includes/ChangeObserverTest.php
index bca8da2..d61483b 100644
--- a/tests/phpunit/includes/ChangeObserverTest.php
+++ b/tests/phpunit/includes/ChangeObserverTest.php
@@ -156,6 +156,38 @@
                        array()
                );
 
+               // #2
+               $title = $this->newMockObject( array(
+                       'getTitle' => $this->newTitle( SMW_NS_PROPERTY )
+               ) )->getMockTitleAccess();
+
+               $provider[] = array(
+                       array(
+                               'settings' => array(
+                                       'smwgEnableUpdateJobs'       => false,
+                                       'smwgDeferredPropertyUpdate' => true
+                               ),
+                               'title' => $title
+                       ),
+                       array()
+               );
+
+               // #3
+               $title = $this->newMockObject( array(
+                       'getTitle' => $this->newTitle( SMW_NS_PROPERTY )
+               ) )->getMockTitleAccess();
+
+               $provider[] = array(
+                       array(
+                               'settings' => array(
+                                       'smwgEnableUpdateJobs'       => false,
+                                       'smwgDeferredPropertyUpdate' => false
+                               ),
+                               'title' => $title
+                       ),
+                       array()
+               );
+
                return $provider;
        }
 

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I55fa837998b939c4f04e24a4b1d4e71c630ee6f0
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/SemanticMediaWiki
Gerrit-Branch: master
Gerrit-Owner: Mwjames <[email protected]>

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

Reply via email to