Phalcon\Test\Unit\Db\Dialect\PostgresqlTest::testAddForeignKey PHP Method

testAddForeignKey() public method

Tests Postgresql::addForeignKey
Since: 2016-09-30
Author: Serghei Iakovlev ([email protected])
public testAddForeignKey ( )
    public function testAddForeignKey()
    {
        $this->specify('The SQL generated to add an index to a table is incorrect', function ($schema, $reference, $expected) {
            $dialect = new Postgresql();
            $references = $this->getReferences();
            expect($dialect->addForeignKey('table', $schema, $references[$reference]))->equals($expected);
        }, ['examples' => $this->getAddForeignKey()]);
    }