Esempio n. 1
0
 function it_can_return_column_by_name(Column $column1, Column $column2, Column $column3)
 {
     $column1->getName()->willReturn('id');
     $column2->getName()->willReturn('firstName');
     $column3->getName()->willReturn('lastName');
     $this->addColumn($column1);
     $this->addColumn($column2);
     $this->addColumn($column3);
     $this->getColumn('lastName')->beAnInstanceOf('Brzoski\\Elements\\Column');
     $this->getColumn('lastName')->getName()->shouldBe('lastName');
 }
Esempio n. 2
0
 function it_return_error_message(Column $column, Table $table)
 {
     $column->getName()->willReturn('users');
     $this->beConstructedWith($column, $table);
     $this->shouldHaveType('Brzoski\\Differences\\ColumnNotExists');
 }