. */ namespace Fisharebest\Webtrees\Census; use Fisharebest\Webtrees\Date; use Fisharebest\Webtrees\Individual; use Mockery; /** * Test harness for the class CensusColumnFullName */ class CensusColumnFullNameTest extends \PHPUnit_Framework_TestCase { /** * Delete mock objects */ public function tearDown() { Mockery::close(); } /** * @covers Fisharebest\Webtrees\Census\CensusColumnFullName * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn */ public function testFullName() { $individual = Mockery::mock(Individual::class); $individual->shouldReceive('getFullName')->andReturn('Joe Bloggs'); $census = Mockery::mock(CensusInterface::class); $column = new CensusColumnFullName($census, '', ''); $this->assertSame('Joe Bloggs', $column->generate($individual)); } }