. */ declare(strict_types=1); namespace Fisharebest\Webtrees\Census; /** * Test harness for the class CensusOfFrance */ class CensusOfFranceTest extends \Fisharebest\Webtrees\TestCase { /** * Test the census place * * @covers \Fisharebest\Webtrees\Census\CensusOfFrance * * @return void */ public function testPlace(): void { $census = new CensusOfFrance(); $this->assertSame('France', $census->censusPlace()); } /** * Test the census dates * * @covers \Fisharebest\Webtrees\Census\CensusOfFrance * * @return void */ public function testAllDates(): void { $census = new CensusOfFrance(); $census_dates = $census->allCensusDates(); $this->assertCount(22, $census_dates); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1831::class, $census_dates[0]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1836::class, $census_dates[1]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1841::class, $census_dates[2]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1846::class, $census_dates[3]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1851::class, $census_dates[4]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1856::class, $census_dates[5]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1861::class, $census_dates[6]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1866::class, $census_dates[7]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1872::class, $census_dates[8]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1876::class, $census_dates[9]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1881::class, $census_dates[10]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1886::class, $census_dates[11]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1891::class, $census_dates[12]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1896::class, $census_dates[13]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1901::class, $census_dates[14]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1906::class, $census_dates[15]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1911::class, $census_dates[16]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1921::class, $census_dates[17]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1926::class, $census_dates[18]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1931::class, $census_dates[19]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1936::class, $census_dates[20]); $this->assertInstanceOf(\Fisharebest\Webtrees\Census\CensusOfFrance1946::class, $census_dates[21]); } }