diff options
| author | Greg Roach <greg@subaqua.co.uk> | 2020-12-30 09:13:04 +0000 |
|---|---|---|
| committer | Greg Roach <greg@subaqua.co.uk> | 2020-12-30 10:48:09 +0000 |
| commit | 5e933c21f8006e675d1df8bcedc634ee61f4aec2 (patch) | |
| tree | c9cc8c537163542486eff0cfdca70187589358b9 /tests/app/Census/CensusColumnBirthPlaceTest.php | |
| parent | 708e66987f7d6eed5675fea31f4074192e368cac (diff) | |
| download | webtrees-5e933c21f8006e675d1df8bcedc634ee61f4aec2.tar.gz webtrees-5e933c21f8006e675d1df8bcedc634ee61f4aec2.tar.bz2 webtrees-5e933c21f8006e675d1df8bcedc634ee61f4aec2.zip | |
Testing
Diffstat (limited to 'tests/app/Census/CensusColumnBirthPlaceTest.php')
| -rw-r--r-- | tests/app/Census/CensusColumnBirthPlaceTest.php | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/tests/app/Census/CensusColumnBirthPlaceTest.php b/tests/app/Census/CensusColumnBirthPlaceTest.php index b0a40a0cd3..f524983e9f 100644 --- a/tests/app/Census/CensusColumnBirthPlaceTest.php +++ b/tests/app/Census/CensusColumnBirthPlaceTest.php @@ -2,7 +2,7 @@ /** * webtrees: online genealogy - * Copyright (C) 2019 webtrees development team + * Copyright (C) 2020 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 @@ -35,9 +35,9 @@ class CensusColumnBirthPlaceTest extends TestCase * * @return Place */ - private function getPlaceMock($place): Place + private function getPlaceMock(string $place): Place { - $placeMock = $this->createMock(Place::class); + $placeMock = self::createMock(Place::class); $placeMock->method('gedcomName')->willReturn($place); return $placeMock; @@ -51,15 +51,15 @@ class CensusColumnBirthPlaceTest extends TestCase */ public function testPlaceCountry(): void { - $individual = $this->createMock(Individual::class); + $individual = self::createMock(Individual::class); $individual->method('getBirthPlace')->willReturn($this->getPlaceMock('Westminster, London, England')); - $census = $this->createMock(CensusInterface::class); + $census = self::createMock(CensusInterface::class); $census->method('censusPlace')->willReturn('England'); $column = new CensusColumnBirthPlace($census, '', ''); - $this->assertSame('Westminster, London', $column->generate($individual, $individual)); + self::assertSame('Westminster, London', $column->generate($individual, $individual)); } /** @@ -70,15 +70,15 @@ class CensusColumnBirthPlaceTest extends TestCase */ public function testPlaceAndCountry(): void { - $individual = $this->createMock(Individual::class); + $individual = self::createMock(Individual::class); $individual->method('getBirthPlace')->willReturn($this->getPlaceMock('England')); - $census = $this->createMock(CensusInterface::class); + $census = self::createMock(CensusInterface::class); $census->method('censusPlace')->willReturn('England'); $column = new CensusColumnBirthPlace($census, '', ''); - $this->assertSame('', $column->generate($individual, $individual)); + self::assertSame('', $column->generate($individual, $individual)); } /** @@ -89,14 +89,14 @@ class CensusColumnBirthPlaceTest extends TestCase */ public function testDifferentCountry(): void { - $individual = $this->createMock(Individual::class); + $individual = self::createMock(Individual::class); $individual->method('getBirthPlace')->willReturn($this->getPlaceMock('Paris, France')); - $census = $this->createMock(CensusInterface::class); + $census = self::createMock(CensusInterface::class); $census->method('censusPlace')->willReturn('England'); $column = new CensusColumnBirthPlace($census, '', ''); - $this->assertSame('Paris, France', $column->generate($individual, $individual)); + self::assertSame('Paris, France', $column->generate($individual, $individual)); } } |
