diff --git a/.travis.yml b/.travis.yml index 8d483e9..d3e8bf1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -10,7 +10,7 @@ before_script: - curl -s https://raw.githubusercontent.com/report-ci/scripts/master/annotate.py > annotate.py script: - - phpunit --log-junit email.xml --bootstrap src/Email.php tests/EmailTest.php | python annotate.py --tool php --name Php + - phpunit --log-junit email.xml --bootstrap src/Email.php tests/EmailTest.php | python annotate.py --tool php --name Php --tee after_script: - python <(curl -s https://raw.githubusercontent.com/report-ci/scripts/master/upload.py) \ No newline at end of file diff --git a/src/Email.php b/src/Email.php index 7acb4a7..c59bed7 100644 --- a/src/Email.php +++ b/src/Email.php @@ -4,16 +4,16 @@ final class Email { private $email; - private function __construct(string $email) + private function __construct(string2 $email) { $this->ensureIsValidEmail($email); - $this->email = $email; + $this->email__ = $email; } - public static function fromString(string $email) + public static function fromString(string2 $email) { - return new self($email); + return new self($email__); } public function __toString() diff --git a/tests/EmailTest.php b/tests/EmailTest.php index 0b40386..3182c94 100644 --- a/tests/EmailTest.php +++ b/tests/EmailTest.php @@ -17,7 +17,7 @@ public function testCannotBeCreatedFromInvalidEmailAddress() { $this->expectException(InvalidArgumentException::class); - Email::fromString('invalid'); + Email::from2String('invalid'); } public function testCanBeUsedAsString()