primaryKey()->after('col_before'), 'int(11) NOT NULL AUTO_INCREMENT PRIMARY KEY AFTER `col_before`' ], [ Schema::TYPE_PK . ' FIRST', $this->primaryKey()->first(), 'int(11) NOT NULL AUTO_INCREMENT PRIMARY KEY FIRST' ], [ Schema::TYPE_PK . ' FIRST', $this->primaryKey()->first()->after('col_before'), 'int(11) NOT NULL AUTO_INCREMENT PRIMARY KEY FIRST' ], [ Schema::TYPE_PK . '(8) AFTER `col_before`', $this->primaryKey(8)->after('col_before'), 'int(8) NOT NULL AUTO_INCREMENT PRIMARY KEY AFTER `col_before`' ], [ Schema::TYPE_PK . '(8) FIRST', $this->primaryKey(8)->first(), 'int(8) NOT NULL AUTO_INCREMENT PRIMARY KEY FIRST' ], [ Schema::TYPE_PK . '(8) FIRST', $this->primaryKey(8)->first()->after('col_before'), 'int(8) NOT NULL AUTO_INCREMENT PRIMARY KEY FIRST' ], [ Schema::TYPE_PK . " COMMENT 'test' AFTER `col_before`", $this->primaryKey()->comment('test')->after('col_before'), "int(11) NOT NULL AUTO_INCREMENT PRIMARY KEY COMMENT 'test' AFTER `col_before`" ], ]); } public function testResetSequence() { $qb = $this->getQueryBuilder(); $expected = 'ALTER TABLE `item` AUTO_INCREMENT=6'; $sql = $qb->resetSequence('item'); $this->assertEquals($expected, $sql); $expected = 'ALTER TABLE `item` AUTO_INCREMENT=4'; $sql = $qb->resetSequence('item', 4); $this->assertEquals($expected, $sql); } }