public function testDropColumn() { $blueprint = new Blueprint('users'); $blueprint->dropColumn('foo'); $statements = $blueprint->toSql($this->getConnection(), $this->getGrammar()); $this->assertEquals(1, count($statements)); $this->assertEquals('alter table "users" drop column "foo"', $statements[0]); $blueprint = new Blueprint('users'); $blueprint->dropColumn(array('foo', 'bar')); $statements = $blueprint->toSql($this->getConnection(), $this->getGrammar()); $this->assertEquals(1, count($statements)); $this->assertEquals('alter table "users" drop column "foo", "bar"', $statements[0]); }
/** * @expectedException BadMethodCallException */ public function testDropColumn() { $blueprint = new Blueprint('users'); $blueprint->dropColumn('foo'); $statements = $blueprint->toSql($this->getConnection(), $this->getGrammar()); }