Replace old URLs in SampleTest

Update URLs to point to documentation for version 6.5, and fix a
couple of broken URLs.

Change-Id: I25211d4da19a40837d7fb7fc6219486f1a7a7c0e
This commit is contained in:
Thalia 2019-05-27 13:35:18 +01:00
parent 5ed6917b4a
commit ff168c8cd7

View file

@ -31,10 +31,8 @@ class SampleTest extends MediaWikiLangTestCase {
/**
* Name tests so that PHPUnit can turn them into sentences when
* they run. While MediaWiki isn't strictly an Agile Programming
* project, you are encouraged to use the naming described under
* "Agile Documentation" at
* https://www.phpunit.de/manual/3.4/en/other-uses-for-tests.html
* they run. You are encouraged to use the naming described at:
* https://phpunit.de/manual/6.5/en/other-uses-for-tests.html
*/
public function testTitleObjectStringConversion() {
$title = Title::newFromText( "text" );
@ -47,7 +45,7 @@ class SampleTest extends MediaWikiLangTestCase {
/**
* If you want to run the same test with a variety of data, use a data provider.
* see: https://www.phpunit.de/manual/3.4/en/writing-tests-for-phpunit.html
* See https://phpunit.de/manual/6.5/en/writing-tests-for-phpunit.html
*/
public static function provideTitles() {
return [
@ -62,7 +60,7 @@ class SampleTest extends MediaWikiLangTestCase {
/**
* phpcs:disable Generic.Files.LineLength
* @dataProvider provideTitles
* See https://phpunit.de/manual/3.7/en/appendixes.annotations.html#appendixes.annotations.dataProvider
* See https://phpunit.de/manual/6.5/en/appendixes.annotations.html#appendixes.annotations.dataProvider
* phpcs:enable
*/
public function testCreateBasicListOfTitles( $titleName, $ns, $text ) {
@ -91,7 +89,7 @@ class SampleTest extends MediaWikiLangTestCase {
/**
* @depends testSetUpMainPageTitleForNextTest
* See https://phpunit.de/manual/3.7/en/appendixes.annotations.html#appendixes.annotations.depends
* See https://phpunit.de/manual/6.5/en/appendixes.annotations.html#appendixes.annotations.depends
*/
public function testCheckMainPageTitleIsConsideredLocal( $title ) {
$this->assertTrue( $title->isLocal() );
@ -99,7 +97,7 @@ class SampleTest extends MediaWikiLangTestCase {
/**
* @expectedException InvalidArgumentException
* See https://phpunit.de/manual/3.7/en/appendixes.annotations.html#appendixes.annotations.expectedException
* See https://phpunit.de/manual/6.5/en/appendixes.annotations.html#appendixes.annotations.expectedException
*/
public function testTitleObjectFromObject() {
$title = Title::newFromText( Title::newFromText( "test" ) );