예제 #1
0
 /**
  * @covers CSanquer\FakeryGenerator\Model\Config::addColumn
  * @covers CSanquer\FakeryGenerator\Model\Config::getColumn
  * @covers CSanquer\FakeryGenerator\Model\Config::removeColumn
  * @covers CSanquer\FakeryGenerator\Model\Config::countColumns
  */
 public function testAddGetRemoveColumn()
 {
     $column = new Column('firstname', '%firstname%');
     $this->assertInstanceOf('\\CSanquer\\FakeryGenerator\\Model\\Config', $this->config->addColumn($column));
     $this->assertSame($column, $this->config->getColumn('firstname'));
     $this->assertEquals(1, $this->config->countColumns());
     $this->assertTrue($this->config->removeColumn($column));
     $this->assertEquals(0, $this->config->countColumns());
     $this->assertNull($this->config->getColumn('firstname'));
     $this->assertFalse($this->config->removeColumn($column));
 }