mirror of
https://github.com/retailcrm/transparent-email.git
synced 2024-11-24 22:36:05 +03:00
Missing return types
This commit is contained in:
parent
beb514e0b3
commit
b4a4050399
@ -23,7 +23,7 @@ class EditableEmailTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($email->getDomain(), $new->getDomain());
|
||||
}
|
||||
|
||||
public function providerRemoveFromLocalPart()
|
||||
public function providerRemoveFromLocalPart() : array
|
||||
{
|
||||
return [
|
||||
[new Email('jane.doe.1990@gmail.com'), '.'],
|
||||
@ -47,7 +47,7 @@ class EditableEmailTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($email->getDomain(), $editable->getDomain());
|
||||
}
|
||||
|
||||
public function providerRemoveSuffixAlias()
|
||||
public function providerRemoveSuffixAlias() : array
|
||||
{
|
||||
return [
|
||||
[new Email('John.Doe+alias@gmail.com', true), '+', 'John.Doe@gmail.com'],
|
||||
@ -71,7 +71,7 @@ class EditableEmailTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($email->getLocalPart(), $new->getLocalPart());
|
||||
}
|
||||
|
||||
public function providerSetDomain()
|
||||
public function providerSetDomain() : array
|
||||
{
|
||||
return [
|
||||
[new Email('jane.doe@foo.bar'), 'gmail.com'],
|
||||
@ -95,7 +95,7 @@ class EditableEmailTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($email->getDomain(), $new->getDomain());
|
||||
}
|
||||
|
||||
public function providerSetLocalPart()
|
||||
public function providerSetLocalPart() : array
|
||||
{
|
||||
return [
|
||||
[new Email('jane.doe@foo.bar'), 'jane'],
|
||||
@ -120,7 +120,7 @@ class EditableEmailTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($email->getDomain(), $new->getDomain());
|
||||
}
|
||||
|
||||
public function providerLowerCaseLocalPartIf()
|
||||
public function providerLowerCaseLocalPartIf() : array
|
||||
{
|
||||
return [
|
||||
[new Email('john.doe@example.com', true), false, true],
|
||||
|
@ -33,7 +33,7 @@ class EmailTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($domain, $object->getDomain());
|
||||
}
|
||||
|
||||
public function providerConstructor()
|
||||
public function providerConstructor() : array
|
||||
{
|
||||
return [
|
||||
['john doe@example.com', true],
|
||||
|
@ -20,7 +20,7 @@ class AppsGoogleComTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($result, (new AppsGoogleCom())->isSupported(new Email('Jane.Doe@' . $domain, true)));
|
||||
}
|
||||
|
||||
public function providerIsSupported()
|
||||
public function providerIsSupported() : array
|
||||
{
|
||||
return [
|
||||
['example.com', false],
|
||||
|
@ -20,7 +20,7 @@ class GmailComTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertEquals($outputEmail, (new GmailCom())->getPrimaryEmail(new Email($inputEmail)));
|
||||
}
|
||||
|
||||
public function providerGetPrimaryEmail()
|
||||
public function providerGetPrimaryEmail() : array
|
||||
{
|
||||
return [
|
||||
['foo.bar@gmail.com', 'foobar@gmail.com'],
|
||||
@ -42,7 +42,7 @@ class GmailComTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($result, (new GmailCom())->isSupported(new Email('Jane.Doe@' . $domain)));
|
||||
}
|
||||
|
||||
public function providerIsSupported()
|
||||
public function providerIsSupported() : array
|
||||
{
|
||||
return [
|
||||
['gmail.com', true],
|
||||
|
@ -21,7 +21,7 @@ class MultiDomainTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($expected, $mock->isSupported(new Email('Jane.Doe@' . $domain, true)));
|
||||
}
|
||||
|
||||
public function providerIsSupported()
|
||||
public function providerIsSupported() : array
|
||||
{
|
||||
return [
|
||||
[$this->getMultiDomainMock('foo.bar', ['foo.bar']), 'gmail.com', false],
|
||||
@ -42,7 +42,7 @@ class MultiDomainTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertEquals($expectedEmail, $mock->getPrimaryEmail(new Email($email, true)));
|
||||
}
|
||||
|
||||
public function providerGetPrimaryDomain()
|
||||
public function providerGetPrimaryDomain() : array
|
||||
{
|
||||
return [
|
||||
[$this->getMultiDomainMock('foo.bar', ['foo.bar', 'foo.bar2']), 'name@foo.bar', 'name@foo.bar'],
|
||||
|
@ -20,7 +20,7 @@ class OutlookComTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($result, (new OutlookCom())->isSupported(new Email('Jane.Doe@' . $domain, true)));
|
||||
}
|
||||
|
||||
public function providerIsSupported()
|
||||
public function providerIsSupported() : array
|
||||
{
|
||||
return [
|
||||
['outlook.com', true],
|
||||
@ -43,7 +43,7 @@ class OutlookComTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertEquals($expectedEmail, (new OutlookCom())->getPrimaryEmail(new Email($inputEmail, true)));
|
||||
}
|
||||
|
||||
public function providerGetPrimaryEmail()
|
||||
public function providerGetPrimaryEmail() : array
|
||||
{
|
||||
return [
|
||||
['janedoe@outlook.com', 'janedoe@outlook.com'],
|
||||
|
@ -20,7 +20,7 @@ class Www33MailComTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($isSupported, (new Www33MailCom())->isSupported(new Email('Jane.Doe@' . $domain, true)));
|
||||
}
|
||||
|
||||
public function providerIsSupported()
|
||||
public function providerIsSupported() : array
|
||||
{
|
||||
return [
|
||||
['foo.33mail.com', true],
|
||||
@ -42,7 +42,7 @@ class Www33MailComTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertEquals($expectedEmail, (new Www33MailCom())->getPrimaryEmail(new Email($inputEmail, true)));
|
||||
}
|
||||
|
||||
public function providerGetPrimaryEmail()
|
||||
public function providerGetPrimaryEmail() : array
|
||||
{
|
||||
return [
|
||||
['qwerty@name.33mail.com', 'name@name.33mail.com'],
|
||||
|
@ -20,7 +20,7 @@ class YahooComTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertSame($result, (new YahooCom())->isSupported(new Email('Jane.Doe@' . $domain, true)));
|
||||
}
|
||||
|
||||
public function providerIsSupported()
|
||||
public function providerIsSupported() : array
|
||||
{
|
||||
return [
|
||||
['yahoo.com', true],
|
||||
@ -44,7 +44,7 @@ class YahooComTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertEquals($expectedEmail, (new YahooCom())->getPrimaryEmail(new Email($inputEmail, true)));
|
||||
}
|
||||
|
||||
public function providerGetPrimaryEmail()
|
||||
public function providerGetPrimaryEmail() : array
|
||||
{
|
||||
return [
|
||||
['janedoe@yahoo.com', 'janedoe@yahoo.com'],
|
||||
|
@ -31,7 +31,7 @@ class TransparentEmailTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertEquals($expectedEmail, $transparentEmail->getPrimaryEmail(new Email($email, $caseSensitive)));
|
||||
}
|
||||
|
||||
public function providerGetPrimaryEmail()
|
||||
public function providerGetPrimaryEmail() : array
|
||||
{
|
||||
$emptyServiceCollector = $this->createServiceCollector();
|
||||
$tlenServiceCollector = $this->createServiceCollector([TlenPl::class]);
|
||||
@ -62,7 +62,7 @@ class TransparentEmailTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertEquals($expectedEmail, (TransparentEmailFactory::createDefault())->getPrimaryEmail($inputEmail));
|
||||
}
|
||||
|
||||
public function providerDefault()
|
||||
public function providerDefault() : array
|
||||
{
|
||||
return [
|
||||
[new Email('John.Doe+spam@gmail.com', true), 'johndoe@gmail.com'],
|
||||
|
Loading…
Reference in New Issue
Block a user