Code Coverage
 
Classes and Traits
Functions and Methods
Lines
Total
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
2 / 2
CRAP
100.00% covered (success)
100.00%
4 / 4
TitleFactoryMainPageUrl
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
2 / 2
2
100.00% covered (success)
100.00%
4 / 4
 __construct
100.00% covered (success)
100.00%
1 / 1
1
100.00% covered (success)
100.00%
2 / 2
 getValue
100.00% covered (success)
100.00%
1 / 1
1
100.00% covered (success)
100.00%
2 / 2
<?php
namespace MediaWiki\Extension\WikibaseManifest;
use TitleFactory;
class TitleFactoryMainPageUrl {
    private $titleFactory;
    /**
     * @param TitleFactory $titleFactory
     */
    public function __construct( TitleFactory $titleFactory ) {
        $this->titleFactory = $titleFactory;
    }
    public function getValue(): string {
        $mainPageTitle = $this->titleFactory->newMainPage();
        return $mainPageTitle->getFullURL();
    }
}