diff options
author | V3n3RiX <venerix@koprulu.sector> | 2022-12-05 21:07:33 +0000 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2022-12-05 21:07:33 +0000 |
commit | 7ac0e89e1c8027ed5be76f6005e8cb52b1e5d484 (patch) | |
tree | 6e8094136a65c722d055bff2797c5e26074dc77e /dev-php/PEAR-Mail/files/PEAR-Mail-1.5.0-fix-tests.patch | |
parent | fbfe3f841f32cbf766cd6ba1d05c3930540be577 (diff) |
gentoo auto-resync : 05:12:2022 - 21:07:33
Diffstat (limited to 'dev-php/PEAR-Mail/files/PEAR-Mail-1.5.0-fix-tests.patch')
-rw-r--r-- | dev-php/PEAR-Mail/files/PEAR-Mail-1.5.0-fix-tests.patch | 74 |
1 files changed, 74 insertions, 0 deletions
diff --git a/dev-php/PEAR-Mail/files/PEAR-Mail-1.5.0-fix-tests.patch b/dev-php/PEAR-Mail/files/PEAR-Mail-1.5.0-fix-tests.patch new file mode 100644 index 000000000000..121d2299206e --- /dev/null +++ b/dev-php/PEAR-Mail/files/PEAR-Mail-1.5.0-fix-tests.patch @@ -0,0 +1,74 @@ +diff --git a/tests/9137.phpt b/tests/9137.phpt
+index ba54c05..2e4c0a5 100644
+--- a/tests/9137.phpt
++++ b/tests/9137.phpt
+@@ -18,7 +18,8 @@ for ($i = 0; $i < count($addresses); $i++) {
+ $address = "\"" . addslashes($addresses[$i]['name']) . "\" ".
+ "<".$addresses[$i]['email'].">";
+
+- $parsedAddresses = Mail_RFC822::parseAddressList($address);
++ $parser = new Mail_RFC822();
++ $parsedAddresses = $parser->parseAddressList($address);
+ if (is_a($parsedAddresses, 'PEAR_Error')) {
+ echo $address." :: Failed to validate\n";
+ } else {
+diff --git a/tests/9137_2.phpt b/tests/9137_2.phpt
+index cc9dcbc..9c3c32d 100644
+--- a/tests/9137_2.phpt
++++ b/tests/9137_2.phpt
+@@ -18,7 +18,8 @@ $addresses = array(
+ for ($i = 0; $i < count($addresses); $i++) {
+ // construct the address
+ $address = $addresses[$i]['raw'];
+- $parsedAddresses = Mail_RFC822::parseAddressList($address);
++ $parser = new Mail_RFC822();
++ $parsedAddresses = $parser->parseAddressList($address);
+ if (PEAR::isError($parsedAddresses)) {
+ echo $address." :: Failed to validate\n";
+ } else {
+diff --git a/tests/bug17178.phpt b/tests/bug17178.phpt
+index 4572dda..425f329 100644
+--- a/tests/bug17178.phpt
++++ b/tests/bug17178.phpt
+@@ -4,7 +4,8 @@ Mail_RFC822::parseAddressList does not accept RFC-valid group syntax
+ <?php
+ require "Mail/RFC822.php";
+
+-var_dump(Mail_RFC822::parseAddressList("empty-group:;","invalid",false,false));
++$parser = new Mail_RFC822();
++var_dump($parser->parseAddressList("empty-group:;","invalid",false,false));
+
+ --EXPECT--
+ array(0) {
+diff --git a/tests/bug17317.phpt b/tests/bug17317.phpt
+index 331e803..045a939 100644
+--- a/tests/bug17317.phpt
++++ b/tests/bug17317.phpt
+@@ -4,9 +4,10 @@ Mail_RFC822::parseAddressList invalid periods in mail address
+ <?php
+ require "Mail/RFC822.php";
+
+-$result[] = Mail_RFC822::parseAddressList('.name@example.com');
+-$result[] = Mail_RFC822::parseAddressList('name.@example.com');
+-$result[] = Mail_RFC822::parseAddressList('name..name@example.com');
++$parser = new Mail_RFC822();
++$result[] = $parser->parseAddressList('.name@example.com');
++$result[] = $parser->parseAddressList('name.@example.com');
++$result[] = $parser->parseAddressList('name..name@example.com');
+
+ foreach ($result as $r) {
+ if (is_a($r, 'PEAR_Error')) {
+diff --git a/tests/validateQuotedString.phpt b/tests/validateQuotedString.phpt
+index 8b892bd..e0adb79 100644
+--- a/tests/validateQuotedString.phpt
++++ b/tests/validateQuotedString.phpt
+@@ -5,7 +5,8 @@ Mail_RFC822::parseAddressList simple tests
+ require_once 'Mail/RFC822.php';
+ $address_string = '"Joe Doe \(from Somewhere\)" <doe@example.com>, postmaster@example.com, root';
+
+-$address_array = Mail_RFC822::parseAddressList($address_string, "example.com");
++$parser = new Mail_RFC822();
++$address_array = $parser->parseAddressList($address_string, "example.com");
+
+ foreach ($address_array as $val) {
+ echo "mailbox : " . $val->mailbox . "\n";
|