diff options
Diffstat (limited to 'tests/app/Census/CensusOfWales1841Test.php')
| -rw-r--r-- | tests/app/Census/CensusOfWales1841Test.php | 83 |
1 files changed, 43 insertions, 40 deletions
diff --git a/tests/app/Census/CensusOfWales1841Test.php b/tests/app/Census/CensusOfWales1841Test.php index 7c3d298108..0d2732578d 100644 --- a/tests/app/Census/CensusOfWales1841Test.php +++ b/tests/app/Census/CensusOfWales1841Test.php @@ -19,49 +19,52 @@ namespace Fisharebest\Webtrees\Census; /** * Test harness for the class CensusOfWales1841 */ -class CensusOfWales1841Test extends \PHPUnit\Framework\TestCase { - /** - * Test the census place and date - * - * @covers \Fisharebest\Webtrees\Census\CensusOfWales1841 - */ - public function testPlaceAndDate() { - $census = new CensusOfWales1841; +class CensusOfWales1841Test extends \PHPUnit\Framework\TestCase +{ + /** + * Test the census place and date + * + * @covers \Fisharebest\Webtrees\Census\CensusOfWales1841 + */ + public function testPlaceAndDate() + { + $census = new CensusOfWales1841; - $this->assertSame('Wales', $census->censusPlace()); - $this->assertSame('06 JUN 1841', $census->censusDate()); - } + $this->assertSame('Wales', $census->censusPlace()); + $this->assertSame('06 JUN 1841', $census->censusDate()); + } - /** - * Test the census columns - * - * @covers \Fisharebest\Webtrees\Census\CensusOfWales1841 - * @covers \Fisharebest\Webtrees\Census\AbstractCensusColumn - */ - public function testColumns() { - $census = new CensusOfWales1841; - $columns = $census->columns(); + /** + * Test the census columns + * + * @covers \Fisharebest\Webtrees\Census\CensusOfWales1841 + * @covers \Fisharebest\Webtrees\Census\AbstractCensusColumn + */ + public function testColumns() + { + $census = new CensusOfWales1841; + $columns = $census->columns(); - $this->assertCount(6, $columns); - $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnFullName', $columns[0]); - $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAgeMale5Years', $columns[1]); - $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAgeFemale5Years', $columns[2]); - $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[3]); - $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNull', $columns[4]); - $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBornForeignParts', $columns[5]); + $this->assertCount(6, $columns); + $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnFullName', $columns[0]); + $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAgeMale5Years', $columns[1]); + $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAgeFemale5Years', $columns[2]); + $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[3]); + $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNull', $columns[4]); + $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBornForeignParts', $columns[5]); - $this->assertSame('Name', $columns[0]->abbreviation()); - $this->assertSame('AgeM', $columns[1]->abbreviation()); - $this->assertSame('AgeF', $columns[2]->abbreviation()); - $this->assertSame('Occupation', $columns[3]->abbreviation()); - $this->assertSame('BiC', $columns[4]->abbreviation()); - $this->assertSame('SIF', $columns[5]->abbreviation()); + $this->assertSame('Name', $columns[0]->abbreviation()); + $this->assertSame('AgeM', $columns[1]->abbreviation()); + $this->assertSame('AgeF', $columns[2]->abbreviation()); + $this->assertSame('Occupation', $columns[3]->abbreviation()); + $this->assertSame('BiC', $columns[4]->abbreviation()); + $this->assertSame('SIF', $columns[5]->abbreviation()); - $this->assertSame('Name', $columns[0]->title()); - $this->assertSame('Age (males)', $columns[1]->title()); - $this->assertSame('Age (females)', $columns[2]->title()); - $this->assertSame('Profession, trade, employment or of independent means', $columns[3]->title()); - $this->assertSame('Born in same county', $columns[4]->title()); - $this->assertSame('Born in Scotland, Ireland or foreign parts', $columns[5]->title()); - } + $this->assertSame('Name', $columns[0]->title()); + $this->assertSame('Age (males)', $columns[1]->title()); + $this->assertSame('Age (females)', $columns[2]->title()); + $this->assertSame('Profession, trade, employment or of independent means', $columns[3]->title()); + $this->assertSame('Born in same county', $columns[4]->title()); + $this->assertSame('Born in Scotland, Ireland or foreign parts', $columns[5]->title()); + } } |
