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

WordPress Trac noreply at wordpress.org
Wed Jun 17 20:06:41 UTC 2020


#50377: phpunit tests fail with - Failed opening required class-phpmailer.php (2)
------------------------------+---------------------
 Reporter:  bwmarkle          |       Owner:  (none)
     Type:  defect (bug)      |      Status:  closed
 Priority:  normal            |   Milestone:  5.5
Component:  Build/Test Tools  |     Version:  trunk
 Severity:  normal            |  Resolution:  fixed
 Keywords:  has-patch         |     Focuses:
------------------------------+---------------------
Changes (by desrosj):

 * status:  new => closed
 * resolution:   => fixed


Comment:

 @bwmarkle shared the [https://travis-ci.org/github/BoldGrid/boldgrid-
 backup/jobs/699149927 failing job] with me on Slack.

 It looks like the problem is with the test install script. The tests are
 being installed from `trunk`, regardless of the `$WP_VERSION` defined. It
 looks like the version being fetched is `latest`, which is an alias to the
 most recent publicly released version (in this case, 5.4.2). This is a
 problem because the files were moved around in `trunk`.

 To fix the tests, the test branch should either be changed to always be
 the latest released version (5.4 in this case), or the install script
 needs to be updated to download the nightly package (which can be found
 here and is refreshed nightly https://wordpress.org/nightly-builds
 /wordpress-latest.zip) instead of the latest public release.

 For an example, check out the [https://github.com/wp-cli/scaffold-
 command/blob/master/templates/install-wp-tests.sh latest install script in
 the WP-CLI scaffolding command]. It is pretty smart about detecting the
 latest version number and checking out the correct version of the test
 library.

 Because this seems like an issue in the plugin repository, I am going to
 close this out. But if it still seems like something is wrong on the core
 side, feel free to reopen with more info.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/50377#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list