[wp-trac] [WordPress Trac] #49377: phpunit tests fail with - Failed opening required class-phpmailer.php

WordPress Trac noreply at wordpress.org
Thu Feb 6 15:40:59 UTC 2020


#49377: phpunit tests fail with - Failed opening required class-phpmailer.php
--------------------------+-----------------------------
 Reporter:  bwmarkle      |      Owner:  (none)
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 This ticket is for the phpunit tests found here:

 https://develop.svn.wordpress.org/branches/5.2/tests/phpunit/includes/

 If I am submitting this ticket in the wrong place, please let me know.


 ----

 Our phpunit tests are failing with the following:

 {{{
 PHP Fatal error:
     require_once():
         Failed opening required '/tmp/wordpress-tests-lib/src//wp-includes
 /class-phpmailer.php'
         (include_path='.:/home/travis/.phpenv/versions/7.1.11/share/pear')
         in /tmp/wordpress-tests-lib/includes/mock-mailer.php on line 2
 }}}

 When troubleshooting, we found two things:

 The path where `class-phpmailer.php` is trying to be loaded from, `/tmp
 /wordpress-tests-lib/src//wp-includes/class-phpmailer.php` is wrong, it
 should be `/tmp/wordpress/wp-includes/class-phpmailer.php`

 For the tests themselves, when using the `5.2` branch instead of `trunk`,
 it works, it seems like something changed recently to cause this.

 Thanks!
 - Brad

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/49377>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list