summaryrefslogtreecommitdiff
path: root/tests/app
diff options
context:
space:
mode:
authorGreg Roach <fisharebest@gmail.com>2016-03-01 00:04:34 +0000
committerGreg Roach <fisharebest@gmail.com>2016-03-01 00:04:34 +0000
commit00225b9840cb4ba8a23967e3fb8fab881d3d63d5 (patch)
tree82da1a0a2bbad1a492238d56da5dce0e8c07fed2 /tests/app
parent68cefffdc99c4b85a44861b9ff0a211f5dad3711 (diff)
downloadwebtrees-00225b9840cb4ba8a23967e3fb8fab881d3d63d5.tar.gz
webtrees-00225b9840cb4ba8a23967e3fb8fab881d3d63d5.tar.bz2
webtrees-00225b9840cb4ba8a23967e3fb8fab881d3d63d5.zip
Fix #854 French censuses
Diffstat (limited to 'tests/app')
-rw-r--r--tests/app/Census/CensusColumnConditionDanishTest.php158
-rw-r--r--tests/app/Census/CensusColumnConditionEnglishTest.php158
-rw-r--r--tests/app/Census/CensusColumnConditionFrenchFemmeTest.php257
-rw-r--r--tests/app/Census/CensusColumnConditionFrenchFilleTest.php257
-rw-r--r--tests/app/Census/CensusColumnConditionFrenchGarconTest.php257
-rw-r--r--tests/app/Census/CensusColumnConditionFrenchHommeTest.php257
-rw-r--r--tests/app/Census/CensusColumnConditionFrenchTest.php115
-rw-r--r--tests/app/Census/CensusColumnConditionFrenchVeufTest.php257
-rw-r--r--tests/app/Census/CensusColumnConditionFrenchVeuveTest.php257
-rw-r--r--tests/app/Census/CensusColumnConditionUsTest.php158
-rw-r--r--tests/app/Census/CensusOfFrance1831Test.php41
-rw-r--r--tests/app/Census/CensusOfFrance1836Test.php41
-rw-r--r--tests/app/Census/CensusOfFrance1841Test.php35
-rw-r--r--tests/app/Census/CensusOfFrance1846Test.php41
-rw-r--r--tests/app/Census/CensusOfFrance1851Test.php58
-rw-r--r--tests/app/Census/CensusOfFrance1856Test.php41
-rw-r--r--tests/app/Census/CensusOfFrance1861Test.php41
-rw-r--r--tests/app/Census/CensusOfFrance1866Test.php41
-rw-r--r--tests/app/Census/CensusOfFrance1872Test.php50
-rw-r--r--tests/app/Census/CensusOfFrance1876Test.php50
-rw-r--r--tests/app/Census/CensusOfFrance1881Test.php20
-rw-r--r--tests/app/Census/CensusOfFrance1886Test.php32
-rw-r--r--tests/app/Census/CensusOfFrance1891Test.php31
-rw-r--r--tests/app/Census/CensusOfFrance1896Test.php32
-rw-r--r--tests/app/Census/CensusOfFrance1901Test.php34
-rw-r--r--tests/app/Census/CensusOfFrance1906Test.php42
-rw-r--r--tests/app/Census/CensusOfFrance1911Test.php42
-rw-r--r--tests/app/Census/CensusOfFrance1921Test.php40
-rw-r--r--tests/app/Census/CensusOfFrance1926Test.php12
-rw-r--r--tests/app/Census/CensusOfFrance1931Test.php12
-rw-r--r--tests/app/Census/CensusOfFrance1936Test.php12
-rw-r--r--tests/app/Census/CensusOfFrance1946Test.php12
32 files changed, 2448 insertions, 443 deletions
diff --git a/tests/app/Census/CensusColumnConditionDanishTest.php b/tests/app/Census/CensusColumnConditionDanishTest.php
index 0f3fc356a1..746ebe10a5 100644
--- a/tests/app/Census/CensusColumnConditionDanishTest.php
+++ b/tests/app/Census/CensusColumnConditionDanishTest.php
@@ -35,13 +35,34 @@ class CensusColumnConditionDanishTest extends \PHPUnit_Framework_TestCase {
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionDanish
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoSpouseFamilies() {
+ public function testNoSpouseFamiliesMale() {
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionDanish($census, '', '');
+
+ $this->assertSame('Ugift', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionDanish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesFemale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
$column = new CensusColumnConditionDanish($census, '', '');
@@ -50,14 +71,36 @@ class CensusColumnConditionDanishTest extends \PHPUnit_Framework_TestCase {
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionDanish
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsMale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionDanish($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('Gift', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionDanish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoFamilyNoFacts() {
+ public function testNoFamilyNoFactsFemale() {
$family = Mockery::mock('Fisharebest\Webtrees\Family');
$family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
$family->shouldReceive('getFacts')->andReturn(array());
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
@@ -70,9 +113,9 @@ class CensusColumnConditionDanishTest extends \PHPUnit_Framework_TestCase {
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionDanish
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoFamilyUnmarried() {
+ public function testNoFamilyUnmarriedMale() {
$fact = Mockery::mock('Fisharebest\Webtrees\Fact');
$family = Mockery::mock('Fisharebest\Webtrees\Family');
@@ -80,21 +123,119 @@ class CensusColumnConditionDanishTest extends \PHPUnit_Framework_TestCase {
$family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
$column = new CensusColumnConditionDanish($census, '', '');
+
+ $this->assertSame('Ugift', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionDanish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
$census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+ $column = new CensusColumnConditionDanish($census, '', '');
+
$this->assertSame('Ugift', $column->generate($individual));
}
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionDanish
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionDanish($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionDanish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionDanish($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionDanish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionDanish($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('Skilt', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionDanish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoFamilyDivorced() {
+ public function testDivorcedFemale() {
$fact = Mockery::mock('Fisharebest\Webtrees\Fact');
$family = Mockery::mock('Fisharebest\Webtrees\Family');
@@ -103,6 +244,7 @@ class CensusColumnConditionDanishTest extends \PHPUnit_Framework_TestCase {
$family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
diff --git a/tests/app/Census/CensusColumnConditionEnglishTest.php b/tests/app/Census/CensusColumnConditionEnglishTest.php
index 19593778ef..e86770ea3c 100644
--- a/tests/app/Census/CensusColumnConditionEnglishTest.php
+++ b/tests/app/Census/CensusColumnConditionEnglishTest.php
@@ -35,13 +35,34 @@ class CensusColumnConditionEnglishTest extends \PHPUnit_Framework_TestCase {
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionEnglish
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoSpouseFamilies() {
+ public function testNoSpouseFamiliesMale() {
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionEnglish($census, '', '');
+
+ $this->assertSame('Unm', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionEnglish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesFemale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
$column = new CensusColumnConditionEnglish($census, '', '');
@@ -50,14 +71,36 @@ class CensusColumnConditionEnglishTest extends \PHPUnit_Framework_TestCase {
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionEnglish
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsMale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionEnglish($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('Mar', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionEnglish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoFamilyNoFacts() {
+ public function testNoFamilyNoFactsFemale() {
$family = Mockery::mock('Fisharebest\Webtrees\Family');
$family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
$family->shouldReceive('getFacts')->andReturn(array());
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
@@ -70,9 +113,9 @@ class CensusColumnConditionEnglishTest extends \PHPUnit_Framework_TestCase {
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionEnglish
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoFamilyUnmarried() {
+ public function testNoFamilyUnmarriedMale() {
$fact = Mockery::mock('Fisharebest\Webtrees\Fact');
$family = Mockery::mock('Fisharebest\Webtrees\Family');
@@ -80,21 +123,119 @@ class CensusColumnConditionEnglishTest extends \PHPUnit_Framework_TestCase {
$family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
$column = new CensusColumnConditionEnglish($census, '', '');
+
+ $this->assertSame('Unm', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionEnglish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
$census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+ $column = new CensusColumnConditionEnglish($census, '', '');
+
$this->assertSame('Unm', $column->generate($individual));
}
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionEnglish
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionEnglish($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionEnglish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionEnglish($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionEnglish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionEnglish($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('Div', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionEnglish
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoFamilyDivorced() {
+ public function testDivorcedFemale() {
$fact = Mockery::mock('Fisharebest\Webtrees\Fact');
$family = Mockery::mock('Fisharebest\Webtrees\Family');
@@ -103,6 +244,7 @@ class CensusColumnConditionEnglishTest extends \PHPUnit_Framework_TestCase {
$family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
diff --git a/tests/app/Census/CensusColumnConditionFrenchFemmeTest.php b/tests/app/Census/CensusColumnConditionFrenchFemmeTest.php
new file mode 100644
index 0000000000..b2642378ac
--- /dev/null
+++ b/tests/app/Census/CensusColumnConditionFrenchFemmeTest.php
@@ -0,0 +1,257 @@
+<?php
+
+/**
+ * webtrees: online genealogy
+ * Copyright (C) 2016 webtrees development team
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+namespace Fisharebest\Webtrees\Census;
+
+use Fisharebest\Webtrees\Date;
+use Fisharebest\Webtrees\Fact;
+use Fisharebest\Webtrees\Family;
+use Fisharebest\Webtrees\Individual;
+use Mockery;
+
+/**
+ * Test harness for the class CensusColumnConditionFrenchFemme
+ */
+class CensusColumnConditionFrenchFemmeTest extends \PHPUnit_Framework_TestCase {
+ /**
+ * Delete mock objects
+ */
+ public function tearDown() {
+ Mockery::close();
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesMale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFemme($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesFemale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFemme($census, '', '');
+
+ $this->assertSame('X', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsMale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchFemme($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsFemale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchFemme($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('X', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFemme($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFemme($census, '', '');
+
+ $this->assertSame('X', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFemme($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFemme($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchFemme($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchFemme($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('X', $column->generate($individual));
+ }
+}
diff --git a/tests/app/Census/CensusColumnConditionFrenchFilleTest.php b/tests/app/Census/CensusColumnConditionFrenchFilleTest.php
new file mode 100644
index 0000000000..5c80f316b6
--- /dev/null
+++ b/tests/app/Census/CensusColumnConditionFrenchFilleTest.php
@@ -0,0 +1,257 @@
+<?php
+
+/**
+ * webtrees: online genealogy
+ * Copyright (C) 2016 webtrees development team
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+namespace Fisharebest\Webtrees\Census;
+
+use Fisharebest\Webtrees\Date;
+use Fisharebest\Webtrees\Fact;
+use Fisharebest\Webtrees\Family;
+use Fisharebest\Webtrees\Individual;
+use Mockery;
+
+/**
+ * Test harness for the class CensusColumnConditionFrenchFille
+ */
+class CensusColumnConditionFrenchFilleTest extends \PHPUnit_Framework_TestCase {
+ /**
+ * Delete mock objects
+ */
+ public function tearDown() {
+ Mockery::close();
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesMale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFille($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesFemale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFille($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsMale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchFille($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsFemale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchFille($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFille($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFille($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFille($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchFille($census, '', '');
+
+ $this->assertSame('X', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchFille($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchFille($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+}
diff --git a/tests/app/Census/CensusColumnConditionFrenchGarconTest.php b/tests/app/Census/CensusColumnConditionFrenchGarconTest.php
new file mode 100644
index 0000000000..18f8130486
--- /dev/null
+++ b/tests/app/Census/CensusColumnConditionFrenchGarconTest.php
@@ -0,0 +1,257 @@
+<?php
+
+/**
+ * webtrees: online genealogy
+ * Copyright (C) 2016 webtrees development team
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+namespace Fisharebest\Webtrees\Census;
+
+use Fisharebest\Webtrees\Date;
+use Fisharebest\Webtrees\Fact;
+use Fisharebest\Webtrees\Family;
+use Fisharebest\Webtrees\Individual;
+use Mockery;
+
+/**
+ * Test harness for the class CensusColumnConditionFrenchGarcon
+ */
+class CensusColumnConditionFrenchGarconTest extends \PHPUnit_Framework_TestCase {
+ /**
+ * Delete mock objects
+ */
+ public function tearDown() {
+ Mockery::close();
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesMale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchGarcon($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesFemale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchGarcon($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsMale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchGarcon($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsFemale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchGarcon($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchGarcon($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchGarcon($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchGarcon($census, '', '');
+
+ $this->assertSame('X', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchGarcon($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchGarcon($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchGarcon($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+}
diff --git a/tests/app/Census/CensusColumnConditionFrenchHommeTest.php b/tests/app/Census/CensusColumnConditionFrenchHommeTest.php
new file mode 100644
index 0000000000..b1d86c68d8
--- /dev/null
+++ b/tests/app/Census/CensusColumnConditionFrenchHommeTest.php
@@ -0,0 +1,257 @@
+<?php
+
+/**
+ * webtrees: online genealogy
+ * Copyright (C) 2016 webtrees development team
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+namespace Fisharebest\Webtrees\Census;
+
+use Fisharebest\Webtrees\Date;
+use Fisharebest\Webtrees\Fact;
+use Fisharebest\Webtrees\Family;
+use Fisharebest\Webtrees\Individual;
+use Mockery;
+
+/**
+ * Test harness for the class CensusColumnConditionFrenchHomme
+ */
+class CensusColumnConditionFrenchHommeTest extends \PHPUnit_Framework_TestCase {
+ /**
+ * Delete mock objects
+ */
+ public function tearDown() {
+ Mockery::close();
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesMale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchHomme($census, '', '');
+
+ $this->assertSame('X', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesFemale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchHomme($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsMale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchHomme($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('X', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsFemale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchHomme($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchHomme($census, '', '');
+
+ $this->assertSame('X', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchHomme($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchHomme($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchHomme($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchHomme($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('X', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchHomme($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+}
diff --git a/tests/app/Census/CensusColumnConditionFrenchTest.php b/tests/app/Census/CensusColumnConditionFrenchTest.php
deleted file mode 100644
index 4fe4c6daed..0000000000
--- a/tests/app/Census/CensusColumnConditionFrenchTest.php
+++ /dev/null
@@ -1,115 +0,0 @@
-<?php
-
-/**
- * webtrees: online genealogy
- * Copyright (C) 2016 webtrees development team
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- */
-namespace Fisharebest\Webtrees\Census;
-
-use Fisharebest\Webtrees\Date;
-use Fisharebest\Webtrees\Fact;
-use Fisharebest\Webtrees\Family;
-use Fisharebest\Webtrees\Individual;
-use Mockery;
-
-/**
- * Test harness for the class CensusColumnConditionFrench
- */
-class CensusColumnConditionFrenchTest extends \PHPUnit_Framework_TestCase {
- /**
- * Delete mock objects
- */
- public function tearDown() {
- Mockery::close();
- }
-
- /**
- * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrench
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
- */
- public function testNoSpouseFamilies() {
- $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
- $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
-
- $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
-
- $column = new CensusColumnConditionFrench($census, '', '');
-
- $this->assertSame('Célibataire', $column->generate($individual));
- }
-
- /**
- * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrench
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
- */
- public function testNoFamilyNoFacts() {
- $family = Mockery::mock('Fisharebest\Webtrees\Family');
- $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
- $family->shouldReceive('getFacts')->andReturn(array());
-
- $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
- $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
-
- $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
-
- $column = new CensusColumnConditionFrench($census, '', '');
- $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
-
- $this->assertSame('Marié', $column->generate($individual));
- }
-
- /**
- * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrench
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
- */
- public function testNoFamilyUnmarried() {
- $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
-
- $family = Mockery::mock('Fisharebest\Webtrees\Family');
- $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
- $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
-
- $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
- $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
-
- $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
-
- $column = new CensusColumnConditionFrench($census, '', '');
- $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
-
- $this->assertSame('Célibataire', $column->generate($individual));
- }
-
- /**
- * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrench
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
- */
- public function testNoFamilyDivorced() {
- $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
-
- $family = Mockery::mock('Fisharebest\Webtrees\Family');
- $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
- $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
- $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
-
- $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
- $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
-
- $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
-
- $column = new CensusColumnConditionFrench($census, '', '');
- $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
-
- $this->assertSame('Divorcé', $column->generate($individual));
- }
-}
diff --git a/tests/app/Census/CensusColumnConditionFrenchVeufTest.php b/tests/app/Census/CensusColumnConditionFrenchVeufTest.php
new file mode 100644
index 0000000000..b35dcdf040
--- /dev/null
+++ b/tests/app/Census/CensusColumnConditionFrenchVeufTest.php
@@ -0,0 +1,257 @@
+<?php
+
+/**
+ * webtrees: online genealogy
+ * Copyright (C) 2016 webtrees development team
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+namespace Fisharebest\Webtrees\Census;
+
+use Fisharebest\Webtrees\Date;
+use Fisharebest\Webtrees\Fact;
+use Fisharebest\Webtrees\Family;
+use Fisharebest\Webtrees\Individual;
+use Mockery;
+
+/**
+ * Test harness for the class CensusColumnConditionFrenchVeuf
+ */
+class CensusColumnConditionFrenchVeufTest extends \PHPUnit_Framework_TestCase {
+ /**
+ * Delete mock objects
+ */
+ public function tearDown() {
+ Mockery::close();
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesMale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuf($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesFemale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuf($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsMale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchVeuf($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsFemale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchVeuf($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuf($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuf($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuf($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuf($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchVeuf($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchVeuf($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+}
diff --git a/tests/app/Census/CensusColumnConditionFrenchVeuveTest.php b/tests/app/Census/CensusColumnConditionFrenchVeuveTest.php
new file mode 100644
index 0000000000..bbf6cf2b35
--- /dev/null
+++ b/tests/app/Census/CensusColumnConditionFrenchVeuveTest.php
@@ -0,0 +1,257 @@
+<?php
+
+/**
+ * webtrees: online genealogy
+ * Copyright (C) 2016 webtrees development team
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+namespace Fisharebest\Webtrees\Census;
+
+use Fisharebest\Webtrees\Date;
+use Fisharebest\Webtrees\Fact;
+use Fisharebest\Webtrees\Family;
+use Fisharebest\Webtrees\Individual;
+use Mockery;
+
+/**
+ * Test harness for the class CensusColumnConditionFrenchVeuve
+ */
+class CensusColumnConditionFrenchVeuveTest extends \PHPUnit_Framework_TestCase {
+ /**
+ * Delete mock objects
+ */
+ public function tearDown() {
+ Mockery::close();
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesMale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuve($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesFemale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuve($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsMale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchVeuve($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsFemale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchVeuve($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuve($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuve($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuve($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionFrenchVeuve($census, '', '');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchVeuve($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionFrenchVeuve($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('', $column->generate($individual));
+ }
+}
diff --git a/tests/app/Census/CensusColumnConditionUsTest.php b/tests/app/Census/CensusColumnConditionUsTest.php
index 4f880fa650..d7fdaaf836 100644
--- a/tests/app/Census/CensusColumnConditionUsTest.php
+++ b/tests/app/Census/CensusColumnConditionUsTest.php
@@ -35,13 +35,34 @@ class CensusColumnConditionUsTest extends \PHPUnit_Framework_TestCase {
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionUs
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoSpouseFamilies() {
+ public function testNoSpouseFamiliesMale() {
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionUs($census, '', '');
+
+ $this->assertSame('S', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionUs
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoSpouseFamiliesFemale() {
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array());
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
$column = new CensusColumnConditionUs($census, '', '');
@@ -50,14 +71,15 @@ class CensusColumnConditionUsTest extends \PHPUnit_Framework_TestCase {
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionUs
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoFamilyNoFacts() {
+ public function testNoFamilyNoFactsMale() {
$family = Mockery::mock('Fisharebest\Webtrees\Family');
$family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
$family->shouldReceive('getFacts')->andReturn(array());
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
@@ -70,9 +92,78 @@ class CensusColumnConditionUsTest extends \PHPUnit_Framework_TestCase {
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionUs
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyNoFactsFemale() {
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->andReturn(array());
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionUs($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('M', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionUs
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionUs($census, '', '');
+
+ $this->assertSame('S', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionUs
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testNoFamilyUnmarriedFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1800'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $column = new CensusColumnConditionUs($census, '', '');
+
+ $this->assertSame('S', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionUs
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoFamilyUnmarried() {
+ public function testChildMale() {
$fact = Mockery::mock('Fisharebest\Webtrees\Fact');
$family = Mockery::mock('Fisharebest\Webtrees\Family');
@@ -80,21 +171,71 @@ class CensusColumnConditionUsTest extends \PHPUnit_Framework_TestCase {
$family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
$column = new CensusColumnConditionUs($census, '', '');
+
+ $this->assertSame('S', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionUs
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testChildFemale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+ $individual->shouldReceive('getEstimatedBirthDate')->andReturn(new Date('1820'));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
$census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+ $column = new CensusColumnConditionUs($census, '', '');
+
$this->assertSame('S', $column->generate($individual));
}
/**
* @covers Fisharebest\Webtrees\Census\CensusColumnConditionUs
- * @covers Fisharebest\Webtrees\Census\AbstractCensusColumn
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
+ */
+ public function testDivorcedMale() {
+ $fact = Mockery::mock('Fisharebest\Webtrees\Fact');
+
+ $family = Mockery::mock('Fisharebest\Webtrees\Family');
+ $family->shouldReceive('getMarriageDate')->andReturn(new Date(''));
+ $family->shouldReceive('getFacts')->with('_NMR')->andReturn(array());
+ $family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
+
+ $individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('M');
+ $individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
+
+ $census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
+
+ $column = new CensusColumnConditionUs($census, '', '');
+ $census->shouldReceive('censusDate')->andReturn('30 JUN 1830');
+
+ $this->assertSame('D', $column->generate($individual));
+ }
+
+ /**
+ * @covers Fisharebest\Webtrees\Census\CensusColumnConditionUs
+ * @covers Fisharebest\Webtrees\Census\AbstractCensusColumnCondition
*/
- public function testNoFamilyDivorced() {
+ public function testDivorcedFemale() {
$fact = Mockery::mock('Fisharebest\Webtrees\Fact');
$family = Mockery::mock('Fisharebest\Webtrees\Family');
@@ -103,6 +244,7 @@ class CensusColumnConditionUsTest extends \PHPUnit_Framework_TestCase {
$family->shouldReceive('getFacts')->with('DIV')->andReturn(array($fact));
$individual = Mockery::mock('Fisharebest\Webtrees\Individual');
+ $individual->shouldReceive('getSex')->andReturn('F');
$individual->shouldReceive('getSpouseFamilies')->andReturn(array($family));
$census = Mockery::mock('Fisharebest\Webtrees\Census\CensusInterface');
diff --git a/tests/app/Census/CensusOfFrance1831Test.php b/tests/app/Census/CensusOfFrance1831Test.php
index 92fad28a6c..69c683ce17 100644
--- a/tests/app/Census/CensusOfFrance1831Test.php
+++ b/tests/app/Census/CensusOfFrance1831Test.php
@@ -42,23 +42,38 @@ class CensusOfFrance1831Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1831;
$columns = $census->columns();
- $this->assertCount(5, $columns);
+ $this->assertCount(10, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthYear', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrench', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme', $columns[7]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve', $columns[8]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[9]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Année', $columns[3]->abbreviation());
- $this->assertSame('Situation pers.', $columns[4]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Titres', $columns[2]->abbreviation());
+ $this->assertSame('Garçons', $columns[3]->abbreviation());
+ $this->assertSame('Hommes', $columns[4]->abbreviation());
+ $this->assertSame('Veufs', $columns[5]->abbreviation());
+ $this->assertSame('Filles', $columns[6]->abbreviation());
+ $this->assertSame('Femmes', $columns[7]->abbreviation());
+ $this->assertSame('Veuves', $columns[8]->abbreviation());
+ $this->assertSame('Âge', $columns[9]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Année de naissance', $columns[3]->title());
- $this->assertSame('Situation personnelle (marié, veuf…)', $columns[4]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Titres, qualifications, état ou profession et fonctions', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('Hommes mariés', $columns[4]->title());
+ $this->assertSame('', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('Femmes mariées', $columns[7]->title());
+ $this->assertSame('', $columns[8]->title());
+ $this->assertSame('', $columns[9]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1836Test.php b/tests/app/Census/CensusOfFrance1836Test.php
index dca098e3cd..2d2d5ecfe6 100644
--- a/tests/app/Census/CensusOfFrance1836Test.php
+++ b/tests/app/Census/CensusOfFrance1836Test.php
@@ -42,23 +42,38 @@ class CensusOfFrance1836Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1836;
$columns = $census->columns();
- $this->assertCount(5, $columns);
+ $this->assertCount(10, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrench', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme', $columns[7]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve', $columns[8]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[9]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
- $this->assertSame('Situation pers.', $columns[4]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Titres', $columns[2]->abbreviation());
+ $this->assertSame('Garçons', $columns[3]->abbreviation());
+ $this->assertSame('Hommes', $columns[4]->abbreviation());
+ $this->assertSame('Veufs', $columns[5]->abbreviation());
+ $this->assertSame('Filles', $columns[6]->abbreviation());
+ $this->assertSame('Femmes', $columns[7]->abbreviation());
+ $this->assertSame('Veuves', $columns[8]->abbreviation());
+ $this->assertSame('Âge', $columns[9]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
- $this->assertSame('Situation personnelle (marié, veuf…)', $columns[4]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Titres, qualifications, état ou profession et fonctions', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('Hommes mariés', $columns[4]->title());
+ $this->assertSame('', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('Femmes mariées', $columns[7]->title());
+ $this->assertSame('', $columns[8]->title());
+ $this->assertSame('', $columns[9]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1841Test.php b/tests/app/Census/CensusOfFrance1841Test.php
index 4ab68fd241..a03bc1737e 100644
--- a/tests/app/Census/CensusOfFrance1841Test.php
+++ b/tests/app/Census/CensusOfFrance1841Test.php
@@ -42,20 +42,35 @@ class CensusOfFrance1841Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1841;
$columns = $census->columns();
- $this->assertCount(4, $columns);
+ $this->assertCount(9, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrench', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme', $columns[7]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve', $columns[8]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Situtation pers.', $columns[3]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Titres', $columns[2]->abbreviation());
+ $this->assertSame('Garçons', $columns[3]->abbreviation());
+ $this->assertSame('Hommes', $columns[4]->abbreviation());
+ $this->assertSame('Veufs', $columns[5]->abbreviation());
+ $this->assertSame('Filles', $columns[6]->abbreviation());
+ $this->assertSame('Femmes', $columns[7]->abbreviation());
+ $this->assertSame('Veuves', $columns[8]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Situation personnelle (marié, veuf…)', $columns[3]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Titres, qualifications, état ou profession et fonctions', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('Hommes mariés', $columns[4]->title());
+ $this->assertSame('', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('Femmes mariées', $columns[7]->title());
+ $this->assertSame('', $columns[8]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1846Test.php b/tests/app/Census/CensusOfFrance1846Test.php
index 2fd9a955f4..f1e7896df7 100644
--- a/tests/app/Census/CensusOfFrance1846Test.php
+++ b/tests/app/Census/CensusOfFrance1846Test.php
@@ -42,23 +42,38 @@ class CensusOfFrance1846Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1846;
$columns = $census->columns();
- $this->assertCount(5, $columns);
+ $this->assertCount(10, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrench', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme', $columns[7]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve', $columns[8]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[9]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
- $this->assertSame('Situtation pers.', $columns[4]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Titres', $columns[2]->abbreviation());
+ $this->assertSame('Garçons', $columns[3]->abbreviation());
+ $this->assertSame('Hommes', $columns[4]->abbreviation());
+ $this->assertSame('Veufs', $columns[5]->abbreviation());
+ $this->assertSame('Filles', $columns[6]->abbreviation());
+ $this->assertSame('Femmes', $columns[7]->abbreviation());
+ $this->assertSame('Veuves', $columns[8]->abbreviation());
+ $this->assertSame('Âge', $columns[9]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
- $this->assertSame('Situation personnelle (marié, veuf…)', $columns[4]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Titres, qualifications, état ou profession et fonctions', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('Hommes mariés', $columns[4]->title());
+ $this->assertSame('', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('Femmes mariées', $columns[7]->title());
+ $this->assertSame('', $columns[8]->title());
+ $this->assertSame('', $columns[9]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1851Test.php b/tests/app/Census/CensusOfFrance1851Test.php
index a5d0cb810c..806a08d05e 100644
--- a/tests/app/Census/CensusOfFrance1851Test.php
+++ b/tests/app/Census/CensusOfFrance1851Test.php
@@ -42,32 +42,46 @@ class CensusOfFrance1851Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1851;
$columns = $census->columns();
- $this->assertCount(8, $columns);
+ $this->assertCount(13, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrench', $columns[4]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNull', $columns[6]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNull', $columns[7]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme', $columns[7]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve', $columns[8]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[9]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNull', $columns[10]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNull', $columns[11]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNull', $columns[12]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
- $this->assertSame('Situtation pers.', $columns[4]->abbreviation());
- $this->assertSame('Nationalité', $columns[5]->abbreviation());
- $this->assertSame('Religion', $columns[6]->abbreviation());
- $this->assertSame('Maladies', $columns[7]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Professions', $columns[2]->abbreviation());
+ $this->assertSame('Garçons', $columns[3]->abbreviation());
+ $this->assertSame('Hommes', $columns[4]->abbreviation());
+ $this->assertSame('Veufs', $columns[5]->abbreviation());
+ $this->assertSame('Filles', $columns[6]->abbreviation());
+ $this->assertSame('Femmes', $columns[7]->abbreviation());
+ $this->assertSame('Veuves', $columns[8]->abbreviation());
+ $this->assertSame('Âge', $columns[9]->abbreviation());
+ $this->assertSame('Fr', $columns[10]->abbreviation());
+ $this->assertSame('Nat', $columns[11]->abbreviation());
+ $this->assertSame('Etr', $columns[12]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
- $this->assertSame('Situation personnelle (marié, veuf…)', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
- $this->assertSame('Religion', $columns[6]->title());
- $this->assertSame('Infirmités et maladies', $columns[7]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('Hommes mariés', $columns[4]->title());
+ $this->assertSame('', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('Femmes mariées', $columns[7]->title());
+ $this->assertSame('', $columns[8]->title());
+ $this->assertSame('Français d’origine', $columns[10]->title());
+ $this->assertSame('Naturalisés français', $columns[11]->title());
+ $this->assertSame('Étrangers (indiquer leur pays d’origine)', $columns[12]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1856Test.php b/tests/app/Census/CensusOfFrance1856Test.php
index afb74dd23d..9fa142e523 100644
--- a/tests/app/Census/CensusOfFrance1856Test.php
+++ b/tests/app/Census/CensusOfFrance1856Test.php
@@ -42,23 +42,38 @@ class CensusOfFrance1856Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1856;
$columns = $census->columns();
- $this->assertCount(5, $columns);
+ $this->assertCount(10, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrench', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme', $columns[7]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve', $columns[8]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[9]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
- $this->assertSame('Situtation pers.', $columns[4]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Titres', $columns[2]->abbreviation());
+ $this->assertSame('Garçons', $columns[3]->abbreviation());
+ $this->assertSame('Hommes', $columns[4]->abbreviation());
+ $this->assertSame('Veufs', $columns[5]->abbreviation());
+ $this->assertSame('Filles', $columns[6]->abbreviation());
+ $this->assertSame('Femmes', $columns[7]->abbreviation());
+ $this->assertSame('Veuves', $columns[8]->abbreviation());
+ $this->assertSame('Âge', $columns[9]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
- $this->assertSame('Situation personnelle (marié, veuf…)', $columns[4]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Titres, qualifications, état ou profession et fonctions', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('Hommes mariés', $columns[4]->title());
+ $this->assertSame('', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('Femmes mariées', $columns[7]->title());
+ $this->assertSame('', $columns[8]->title());
+ $this->assertSame('', $columns[9]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1861Test.php b/tests/app/Census/CensusOfFrance1861Test.php
index db35c2dfa1..5e87580690 100644
--- a/tests/app/Census/CensusOfFrance1861Test.php
+++ b/tests/app/Census/CensusOfFrance1861Test.php
@@ -42,23 +42,38 @@ class CensusOfFrance1861Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1861;
$columns = $census->columns();
- $this->assertCount(5, $columns);
+ $this->assertCount(10, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrench', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme', $columns[7]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve', $columns[8]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[9]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
- $this->assertSame('Situtation pers.', $columns[4]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Titres', $columns[2]->abbreviation());
+ $this->assertSame('Garçons', $columns[3]->abbreviation());
+ $this->assertSame('Hommes', $columns[4]->abbreviation());
+ $this->assertSame('Veufs', $columns[5]->abbreviation());
+ $this->assertSame('Filles', $columns[6]->abbreviation());
+ $this->assertSame('Femmes', $columns[7]->abbreviation());
+ $this->assertSame('Veuves', $columns[8]->abbreviation());
+ $this->assertSame('Âge', $columns[9]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
- $this->assertSame('Situation personnelle (marié, veuf…)', $columns[4]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Titres, qualifications, état ou profession et fonctions', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('Hommes mariés', $columns[4]->title());
+ $this->assertSame('', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('Femmes mariées', $columns[7]->title());
+ $this->assertSame('', $columns[8]->title());
+ $this->assertSame('', $columns[9]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1866Test.php b/tests/app/Census/CensusOfFrance1866Test.php
index e736fb8dde..528d867cfb 100644
--- a/tests/app/Census/CensusOfFrance1866Test.php
+++ b/tests/app/Census/CensusOfFrance1866Test.php
@@ -42,23 +42,38 @@ class CensusOfFrance1866Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1866;
$columns = $census->columns();
- $this->assertCount(5, $columns);
+ $this->assertCount(10, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrench', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme', $columns[7]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve', $columns[8]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[9]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
- $this->assertSame('Situtation pers.', $columns[4]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Titres', $columns[2]->abbreviation());
+ $this->assertSame('Garçons', $columns[3]->abbreviation());
+ $this->assertSame('Hommes', $columns[4]->abbreviation());
+ $this->assertSame('Veufs', $columns[5]->abbreviation());
+ $this->assertSame('Filles', $columns[6]->abbreviation());
+ $this->assertSame('Femmes', $columns[7]->abbreviation());
+ $this->assertSame('Veuves', $columns[8]->abbreviation());
+ $this->assertSame('Âge', $columns[9]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
- $this->assertSame('Situation personnelle (marié, veuf…)', $columns[4]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Titres, qualifications, état ou profession et fonctions', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('Hommes mariés', $columns[4]->title());
+ $this->assertSame('', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('Femmes mariées', $columns[7]->title());
+ $this->assertSame('', $columns[8]->title());
+ $this->assertSame('', $columns[9]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1872Test.php b/tests/app/Census/CensusOfFrance1872Test.php
index eef77cfa42..d8c9e8295d 100644
--- a/tests/app/Census/CensusOfFrance1872Test.php
+++ b/tests/app/Census/CensusOfFrance1872Test.php
@@ -42,29 +42,41 @@ class CensusOfFrance1872Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1872;
$columns = $census->columns();
- $this->assertCount(7, $columns);
+ $this->assertCount(11, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrench', $columns[4]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthPlace', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme', $columns[7]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve', $columns[8]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[9]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthPlace', $columns[10]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
- $this->assertSame('Situtation pers.', $columns[4]->abbreviation());
- $this->assertSame('Nationalité', $columns[5]->abbreviation());
- $this->assertSame('Lieu', $columns[6]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Titres', $columns[2]->abbreviation());
+ $this->assertSame('Garçons', $columns[3]->abbreviation());
+ $this->assertSame('Hommes', $columns[4]->abbreviation());
+ $this->assertSame('Veufs', $columns[5]->abbreviation());
+ $this->assertSame('Filles', $columns[6]->abbreviation());
+ $this->assertSame('Femmes', $columns[7]->abbreviation());
+ $this->assertSame('Veuves', $columns[8]->abbreviation());
+ $this->assertSame('Âge', $columns[9]->abbreviation());
+ $this->assertSame('Nationalité', $columns[10]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
- $this->assertSame('Situation personnelle (marié, veuf…)', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
- $this->assertSame('Lieu de naissance', $columns[6]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Titres, qualifications, état ou profession et fonctions', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('Hommes mariés', $columns[4]->title());
+ $this->assertSame('', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('Femmes mariées', $columns[7]->title());
+ $this->assertSame('', $columns[8]->title());
+ $this->assertSame('', $columns[9]->title());
+ $this->assertSame('Nationalité - Lieu de naissance', $columns[10]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1876Test.php b/tests/app/Census/CensusOfFrance1876Test.php
index 2d7c59fe05..4adf29fe83 100644
--- a/tests/app/Census/CensusOfFrance1876Test.php
+++ b/tests/app/Census/CensusOfFrance1876Test.php
@@ -42,29 +42,41 @@ class CensusOfFrance1876Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1876;
$columns = $census->columns();
- $this->assertCount(7, $columns);
+ $this->assertCount(11, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrench', $columns[4]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthPlace', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchGarcon', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchHomme', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuf', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFille', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchFemme', $columns[7]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnConditionFrenchVeuve', $columns[8]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[9]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthPlace', $columns[10]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
- $this->assertSame('Situtation pers.', $columns[4]->abbreviation());
- $this->assertSame('Nationalité', $columns[5]->abbreviation());
- $this->assertSame('Lieu', $columns[6]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Titres', $columns[2]->abbreviation());
+ $this->assertSame('Garçons', $columns[3]->abbreviation());
+ $this->assertSame('Hommes', $columns[4]->abbreviation());
+ $this->assertSame('Veufs', $columns[5]->abbreviation());
+ $this->assertSame('Filles', $columns[6]->abbreviation());
+ $this->assertSame('Femmes', $columns[7]->abbreviation());
+ $this->assertSame('Veuves', $columns[8]->abbreviation());
+ $this->assertSame('Âge', $columns[9]->abbreviation());
+ $this->assertSame('Nationalité', $columns[10]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
- $this->assertSame('Situation personnelle (marié, veuf…)', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
- $this->assertSame('Lieu de naissance', $columns[6]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Titres, qualifications, état ou profession et fonctions', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('Hommes mariés', $columns[4]->title());
+ $this->assertSame('', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('Femmes mariées', $columns[7]->title());
+ $this->assertSame('', $columns[8]->title());
+ $this->assertSame('', $columns[9]->title());
+ $this->assertSame('Nationalité - Lieu de naissance', $columns[10]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1881Test.php b/tests/app/Census/CensusOfFrance1881Test.php
index 1531ccee3b..0c0204377f 100644
--- a/tests/app/Census/CensusOfFrance1881Test.php
+++ b/tests/app/Census/CensusOfFrance1881Test.php
@@ -45,20 +45,20 @@ class CensusOfFrance1881Test extends \PHPUnit_Framework_TestCase {
$this->assertCount(5, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[2]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[3]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[4]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Âge', $columns[2]->abbreviation());
+ $this->assertSame('Profession', $columns[3]->abbreviation());
$this->assertSame('Position', $columns[4]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
$this->assertSame('Position dans le ménage', $columns[4]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1886Test.php b/tests/app/Census/CensusOfFrance1886Test.php
index efb990fe1b..21f741728f 100644
--- a/tests/app/Census/CensusOfFrance1886Test.php
+++ b/tests/app/Census/CensusOfFrance1886Test.php
@@ -45,23 +45,23 @@ class CensusOfFrance1886Test extends \PHPUnit_Framework_TestCase {
$this->assertCount(6, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[4]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[2]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[5]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
- $this->assertSame('Position', $columns[4]->abbreviation());
- $this->assertSame('Nationalité', $columns[5]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Âge', $columns[2]->abbreviation());
+ $this->assertSame('Nationalité', $columns[3]->abbreviation());
+ $this->assertSame('Profession', $columns[4]->abbreviation());
+ $this->assertSame('Position', $columns[5]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
- $this->assertSame('Position dans le ménage', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('', $columns[4]->title());
+ $this->assertSame('Position dans le ménage', $columns[5]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1891Test.php b/tests/app/Census/CensusOfFrance1891Test.php
index d578648606..5be238cc7b 100644
--- a/tests/app/Census/CensusOfFrance1891Test.php
+++ b/tests/app/Census/CensusOfFrance1891Test.php
@@ -42,23 +42,26 @@ class CensusOfFrance1891Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1891;
$columns = $census->columns();
- $this->assertCount(5, $columns);
+ $this->assertCount(6, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[2]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[5]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Position', $columns[3]->abbreviation());
- $this->assertSame('Nationalité', $columns[4]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Âge', $columns[2]->abbreviation());
+ $this->assertSame('Nationalité', $columns[3]->abbreviation());
+ $this->assertSame('Profession', $columns[4]->abbreviation());
+ $this->assertSame('Position', $columns[5]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Position dans le ménage', $columns[3]->title());
- $this->assertSame('Nationalité', $columns[4]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('', $columns[4]->title());
+ $this->assertSame('Position dans le ménage', $columns[5]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1896Test.php b/tests/app/Census/CensusOfFrance1896Test.php
index c1ccb4685f..0565393eb0 100644
--- a/tests/app/Census/CensusOfFrance1896Test.php
+++ b/tests/app/Census/CensusOfFrance1896Test.php
@@ -45,23 +45,23 @@ class CensusOfFrance1896Test extends \PHPUnit_Framework_TestCase {
$this->assertCount(6, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[4]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[2]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[5]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
- $this->assertSame('Position', $columns[4]->abbreviation());
- $this->assertSame('Nationalité', $columns[5]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Âge', $columns[2]->abbreviation());
+ $this->assertSame('Nationalité', $columns[3]->abbreviation());
+ $this->assertSame('Profession', $columns[4]->abbreviation());
+ $this->assertSame('Position', $columns[5]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
- $this->assertSame('Position dans le ménage', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('', $columns[4]->title());
+ $this->assertSame('Position dans le ménage', $columns[5]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1901Test.php b/tests/app/Census/CensusOfFrance1901Test.php
index 6fbc4f63e1..a933f6ece3 100644
--- a/tests/app/Census/CensusOfFrance1901Test.php
+++ b/tests/app/Census/CensusOfFrance1901Test.php
@@ -45,29 +45,29 @@ class CensusOfFrance1901Test extends \PHPUnit_Framework_TestCase {
$this->assertCount(8, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnAge', $columns[2]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[3]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[4]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[5]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthPlace', $columns[6]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNull', $columns[7]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Âge', $columns[3]->abbreviation());
- $this->assertSame('Position', $columns[4]->abbreviation());
- $this->assertSame('Nationalité', $columns[5]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Âge', $columns[2]->abbreviation());
+ $this->assertSame('Nationalité', $columns[3]->abbreviation());
+ $this->assertSame('Situation', $columns[4]->abbreviation());
+ $this->assertSame('Profession', $columns[5]->abbreviation());
$this->assertSame('Lieu', $columns[6]->abbreviation());
- $this->assertSame('Position sociale', $columns[7]->abbreviation());
+ $this->assertSame('Empl', $columns[7]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Âge', $columns[3]->title());
- $this->assertSame('Position dans le ménage', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('', $columns[2]->title());
+ $this->assertSame('', $columns[3]->title());
+ $this->assertSame('Situation par rapport au chef de ménage', $columns[4]->title());
+ $this->assertSame('', $columns[5]->title());
$this->assertSame('Lieu de naissance', $columns[6]->title());
- $this->assertSame('Position sociale (patron, ouvrier ou employé)', $columns[7]->title());
+ $this->assertSame('', $columns[7]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1906Test.php b/tests/app/Census/CensusOfFrance1906Test.php
index 4deffebbd8..66a7ef4d2f 100644
--- a/tests/app/Census/CensusOfFrance1906Test.php
+++ b/tests/app/Census/CensusOfFrance1906Test.php
@@ -45,29 +45,29 @@ class CensusOfFrance1906Test extends \PHPUnit_Framework_TestCase {
$this->assertCount(8, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthYear', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[4]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthPlace', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthYear', $columns[2]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthPlace', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[6]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNull', $columns[7]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Année', $columns[3]->abbreviation());
- $this->assertSame('Position', $columns[4]->abbreviation());
- $this->assertSame('Nationalité', $columns[5]->abbreviation());
- $this->assertSame('Lieu', $columns[6]->abbreviation());
- $this->assertSame('Position sociale', $columns[7]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Année', $columns[2]->abbreviation());
+ $this->assertSame('Lieu', $columns[3]->abbreviation());
+ $this->assertSame('Nationalité', $columns[4]->abbreviation());
+ $this->assertSame('Situation', $columns[5]->abbreviation());
+ $this->assertSame('Profession', $columns[6]->abbreviation());
+ $this->assertSame('Empl', $columns[7]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Année de naissance', $columns[3]->title());
- $this->assertSame('Position dans le ménage', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
- $this->assertSame('Lieu de naissance', $columns[6]->title());
- $this->assertSame('Position sociale (patron, ouvrier ou employé)', $columns[7]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Année de naissance', $columns[2]->title());
+ $this->assertSame('Lieu de naissance', $columns[3]->title());
+ $this->assertSame('', $columns[4]->title());
+ $this->assertSame('Situation par rapport au chef de ménage', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('', $columns[7]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1911Test.php b/tests/app/Census/CensusOfFrance1911Test.php
index 3ba9ff6be8..3ab9aee19c 100644
--- a/tests/app/Census/CensusOfFrance1911Test.php
+++ b/tests/app/Census/CensusOfFrance1911Test.php
@@ -45,29 +45,29 @@ class CensusOfFrance1911Test extends \PHPUnit_Framework_TestCase {
$this->assertCount(8, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthYear', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[4]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthPlace', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthYear', $columns[2]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthPlace', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[6]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNull', $columns[7]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Année', $columns[3]->abbreviation());
- $this->assertSame('Position', $columns[4]->abbreviation());
- $this->assertSame('Nationalité', $columns[5]->abbreviation());
- $this->assertSame('Lieu', $columns[6]->abbreviation());
- $this->assertSame('Position sociale', $columns[7]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Année', $columns[2]->abbreviation());
+ $this->assertSame('Lieu', $columns[3]->abbreviation());
+ $this->assertSame('Nationalité', $columns[4]->abbreviation());
+ $this->assertSame('Situation', $columns[5]->abbreviation());
+ $this->assertSame('Profession', $columns[6]->abbreviation());
+ $this->assertSame('Empl', $columns[7]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Année de naissance', $columns[3]->title());
- $this->assertSame('Position dans le ménage', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
- $this->assertSame('Lieu de naissance', $columns[6]->title());
- $this->assertSame('Position sociale (patron, ouvrier ou employé)', $columns[7]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Année de naissance', $columns[2]->title());
+ $this->assertSame('Lieu de naissance', $columns[3]->title());
+ $this->assertSame('', $columns[4]->title());
+ $this->assertSame('Situation par rapport au chef de ménage', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('', $columns[7]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1921Test.php b/tests/app/Census/CensusOfFrance1921Test.php
index 26d7fcb6ff..cceb57851e 100644
--- a/tests/app/Census/CensusOfFrance1921Test.php
+++ b/tests/app/Census/CensusOfFrance1921Test.php
@@ -42,26 +42,32 @@ class CensusOfFrance1921Test extends \PHPUnit_Framework_TestCase {
$census = new CensusOfFrance1921;
$columns = $census->columns();
- $this->assertCount(6, $columns);
+ $this->assertCount(8, $columns);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnSurname', $columns[0]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnGivenNames', $columns[1]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[2]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthYear', $columns[3]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[4]);
- $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthYear', $columns[2]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnBirthPlace', $columns[3]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[4]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[5]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnOccupation', $columns[6]);
+ $this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNull', $columns[7]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
- $this->assertSame('Profession', $columns[2]->abbreviation());
- $this->assertSame('Année', $columns[3]->abbreviation());
- $this->assertSame('Position', $columns[4]->abbreviation());
- $this->assertSame('Nationalité', $columns[5]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
+ $this->assertSame('Année', $columns[2]->abbreviation());
+ $this->assertSame('Lieu', $columns[3]->abbreviation());
+ $this->assertSame('Nationalité', $columns[4]->abbreviation());
+ $this->assertSame('Situation', $columns[5]->abbreviation());
+ $this->assertSame('Profession', $columns[6]->abbreviation());
+ $this->assertSame('Empl', $columns[7]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
- $this->assertSame('Année de naissance', $columns[3]->title());
- $this->assertSame('Position dans le ménage', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('Année de naissance', $columns[2]->title());
+ $this->assertSame('Lieu de naissance', $columns[3]->title());
+ $this->assertSame('', $columns[4]->title());
+ $this->assertSame('Situation par rapport au chef de ménage', $columns[5]->title());
+ $this->assertSame('', $columns[6]->title());
+ $this->assertSame('', $columns[7]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1926Test.php b/tests/app/Census/CensusOfFrance1926Test.php
index 4347edc719..650911cf28 100644
--- a/tests/app/Census/CensusOfFrance1926Test.php
+++ b/tests/app/Census/CensusOfFrance1926Test.php
@@ -50,18 +50,18 @@ class CensusOfFrance1926Test extends \PHPUnit_Framework_TestCase {
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[4]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
$this->assertSame('Profession', $columns[2]->abbreviation());
$this->assertSame('Année', $columns[3]->abbreviation());
$this->assertSame('Position', $columns[4]->abbreviation());
$this->assertSame('Nationalité', $columns[5]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('', $columns[2]->title());
$this->assertSame('Année de naissance', $columns[3]->title());
$this->assertSame('Position dans le ménage', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
+ $this->assertSame('', $columns[5]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1931Test.php b/tests/app/Census/CensusOfFrance1931Test.php
index 08756a4585..8787c73e84 100644
--- a/tests/app/Census/CensusOfFrance1931Test.php
+++ b/tests/app/Census/CensusOfFrance1931Test.php
@@ -50,18 +50,18 @@ class CensusOfFrance1931Test extends \PHPUnit_Framework_TestCase {
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[4]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
$this->assertSame('Profession', $columns[2]->abbreviation());
$this->assertSame('Année', $columns[3]->abbreviation());
$this->assertSame('Position', $columns[4]->abbreviation());
$this->assertSame('Nationalité', $columns[5]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('', $columns[2]->title());
$this->assertSame('Année de naissance', $columns[3]->title());
$this->assertSame('Position dans le ménage', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
+ $this->assertSame('', $columns[5]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1936Test.php b/tests/app/Census/CensusOfFrance1936Test.php
index 9d8024eb28..b706e2d12d 100644
--- a/tests/app/Census/CensusOfFrance1936Test.php
+++ b/tests/app/Census/CensusOfFrance1936Test.php
@@ -50,18 +50,18 @@ class CensusOfFrance1936Test extends \PHPUnit_Framework_TestCase {
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[4]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
$this->assertSame('Profession', $columns[2]->abbreviation());
$this->assertSame('Année', $columns[3]->abbreviation());
$this->assertSame('Position', $columns[4]->abbreviation());
$this->assertSame('Nationalité', $columns[5]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('', $columns[2]->title());
$this->assertSame('Année de naissance', $columns[3]->title());
$this->assertSame('Position dans le ménage', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
+ $this->assertSame('', $columns[5]->title());
}
}
diff --git a/tests/app/Census/CensusOfFrance1946Test.php b/tests/app/Census/CensusOfFrance1946Test.php
index cbe1e4f30f..3e43846526 100644
--- a/tests/app/Census/CensusOfFrance1946Test.php
+++ b/tests/app/Census/CensusOfFrance1946Test.php
@@ -50,18 +50,18 @@ class CensusOfFrance1946Test extends \PHPUnit_Framework_TestCase {
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnRelationToHead', $columns[4]);
$this->assertInstanceOf('Fisharebest\Webtrees\Census\CensusColumnNationality', $columns[5]);
- $this->assertSame('Nom', $columns[0]->abbreviation());
- $this->assertSame('Prénom', $columns[1]->abbreviation());
+ $this->assertSame('Noms', $columns[0]->abbreviation());
+ $this->assertSame('Prénoms', $columns[1]->abbreviation());
$this->assertSame('Profession', $columns[2]->abbreviation());
$this->assertSame('Année', $columns[3]->abbreviation());
$this->assertSame('Position', $columns[4]->abbreviation());
$this->assertSame('Nationalité', $columns[5]->abbreviation());
- $this->assertSame('Nom de famille', $columns[0]->title());
- $this->assertSame('Prénom', $columns[1]->title());
- $this->assertSame('Profession', $columns[2]->title());
+ $this->assertSame('Noms de famille', $columns[0]->title());
+ $this->assertSame('', $columns[1]->title());
+ $this->assertSame('', $columns[2]->title());
$this->assertSame('Année de naissance', $columns[3]->title());
$this->assertSame('Position dans le ménage', $columns[4]->title());
- $this->assertSame('Nationalité', $columns[5]->title());
+ $this->assertSame('', $columns[5]->title());
}
}