ApiPlatform\Core\Tests\Doctrine\Util\QueryJoinParserTest::testGetJoinAliasWithReflection PHP Method

testGetJoinAliasWithReflection() public method

    public function testGetJoinAliasWithReflection()
    {
        $methodExist = $this->getFunctionMock('ApiPlatform\\Core\\Bridge\\Doctrine\\Orm\\Util', 'method_exists');
        $methodExist->expects($this->any())->with(Join::class, 'getAlias')->willReturn('false');
        $join = new Join('INNER_JOIN', 'relatedDummy', 'a_1', null, 'a_1.name = r.name');
        $this->assertEquals('a_1', QueryJoinParser::getJoinAlias($join));
    }