Make WordPress Core

Opened 5 years ago

Last modified 2 months ago

#50266 new enhancement

Had to specify mysql socket to run php automated test

Reported by: mmarco9's profile mmarco9 Owned by:
Milestone: Awaiting Review Priority: normal
Severity: minor Version:
Component: Build/Test Tools Keywords: reporter-feedback close
Focuses: docs Cc:

Description

I had to add mysql socket information to be able to run phpunit. Without it, phpunit complained that it could not connect to database. Hopefully someone can confirm this and add this information to the docs.

Example in wp-tests-config.php:
define( 'DB_HOST', 'localhost:/Applications/MAMP/tmp/mysql/mysql.sock' );

I followed all the instructions from here: https://make.wordpress.org/core/handbook/testing/automated-testing/phpunit/ . I am using MacOS Catalina 10.15.2.

Change History (2)

#1 @SergeyBiryukov
5 years ago

  • Component changed from General to Build/Test Tools

#2 @desrosj
2 months ago

  • Keywords reporter-feedback close added

Hi @mmarco9,

Welcome to Trac! My apologies that this took so long to receive a response.

I don't use MAMP, so I'm unable to confirm whether this is still an issue or not. If you still use the tool, could you please provide an update?

It's been roughly 4 years and no one else has reported this problem, so I'm wondering if it was an issue with your setup at the time. With that in mind, I'm going to mark as a close suggestion pending more details from you as it seems no one else has encountered this exact issue.

Note: See TracTickets for help on using tickets.