<commit_before><?php

namespace OpenOrchestra\FrontBundle\Tests\Routing;

use Phake;
use OpenOrchestra\FrontBundle\Routing\OpenOrchestraRouter;
use Symfony\Component\Routing\RouteCollection;

/**
 * Tests of OpenOrchestraUrlRouter
 */
class OpenOrchestraRouterTest extends \PHPUnit_Framework_TestCase
{
    protected $router;

    /**
     * Set up the test
     */
    public function setUp()
    {
        $requestStack = Phake::mock('Symfony\Component\HttpFoundation\RequestStack');

        $mockRoutingLoader = Phake::mock('Symfony\Bundle\FrameworkBundle\Routing\DelegatingLoader');
        Phake::when($mockRoutingLoader)->load(Phake::anyParameters())->thenReturn(new RouteCollection());

        $container = Phake::mock('Symfony\Component\DependencyInjection\ContainerInterface');
        Phake::when($container)->get('routing.loader')->thenReturn($mockRoutingLoader);
        Phake::when($container)->get('request_stack')->thenReturn($requestStack);

        $this->router = new OpenOrchestraRouter(
            $container,
            null,
            array(
                'generator_class' => 'OpenOrchestra\FrontBundle\Routing\OpenOrchestraUrlGenerator',
                'generator_base_class' => 'OpenOrchestra\FrontBundle\Routing\OpenOrchestraUrlGenerator',
            )
        );
    }

    /**
     * test get generator
     */
    public function testGetGenerator()
    {
        $this->assertInstanceOf(
            'OpenOrchestra\\FrontBundle\\Routing\\OpenOrchestraUrlGenerator',
            $this->router->getGenerator()
        );
    }
}<commit_msg>update test coverage<commit_after><?php

namespace OpenOrchestra\FrontBundle\Tests\Routing;

use Phake;
use OpenOrchestra\FrontBundle\Routing\OpenOrchestraRouter;
use Symfony\Component\Routing\RouteCollection;

/**
 * Tests of OpenOrchestraUrlRouter
 */
class OpenOrchestraRouterTest extends \PHPUnit_Framework_TestCase
{
    /**
     * @var OpenOrchestraRouter
     */
    protected $router;

    /**
     * Set up the test
     */
    public function setUp()
    {
        $requestStack = Phake::mock('Symfony\Component\HttpFoundation\RequestStack');

        $mockRoutingLoader = Phake::mock('Symfony\Bundle\FrameworkBundle\Routing\DelegatingLoader');
        Phake::when($mockRoutingLoader)->load(Phake::anyParameters())->thenReturn(new RouteCollection());

        $container = Phake::mock('Symfony\Component\DependencyInjection\ContainerInterface');
        Phake::when($container)->get('routing.loader')->thenReturn($mockRoutingLoader);
        Phake::when($container)->get('request_stack')->thenReturn($requestStack);

        $this->router = new OpenOrchestraRouter(
            $container,
            null,
            array(
                'generator_class' => 'OpenOrchestra\FrontBundle\Routing\OpenOrchestraUrlGenerator',
                'generator_base_class' => 'OpenOrchestra\FrontBundle\Routing\OpenOrchestraUrlGenerator',
            )
        );
    }

    /**
     * test get generator
     */
    public function testGetGenerator()
    {
        $generator = $this->router->getGenerator();
        $this->assertInstanceOf(
            'OpenOrchestra\\FrontBundle\\Routing\\OpenOrchestraUrlGenerator',
            $generator
        );
        $this->assertSame($generator, $this->router->getGenerator());
    }
}
{'fraction_non_alphanumeric': 0.12560386473429952, 'fraction_numerical': 0.0, 'mean_word_length': 3.14125, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 30, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6955795', 'n_tokens_mistral': 879, 'n_tokens_neox': 912, 'n_words': 116}