Board index   FAQ   Search  
Register  Login
Board index PHP PHP Installation

Setup mysql user,passwd,db for make test

Forum for you who has PHP installation issues

Moderators: macek, egami, gesf

Setup mysql user,passwd,db for make test

Postby vitantonio » Fri Mar 21, 2014 6:24 am

Hi,

I am compiling php 5.5.10 from source on Mac OSX Mavericks and ubuntu server 13.10. Everything goes fine except I cannot get the mysql/mysqli tests to run. By default they are set up to use user 'root', no password, db 'test'. I have removed the root user and test db from mysql for security reasons. I set up a special user, password, and db specifically for the php tests. After investigating I found 'connect.inc' files in the tests directory that assign the user, password and db to use for the tests:
Code: Select all
$user = getenv("MYSQL_TEST_USER") ? getenv("MYSQL_TEST_USER") : "root";
$passwd  = getenv("MYSQL_TEST_PASSWD")  ? getenv("MYSQL_TEST_PASSWD") : "";
$db = getenv("MYSQL_TEST_DB") ? getenv("MYSQL_TEST_DB") : "test";

Soo... I ran make test with:
Code: Select all
export MYSQL_TEST_USER='jonniebegood'
export MYSQL_TEST_PASSWD='whatever'
export MYSQL_TEST_DB='test-for-php'
make test

This does NOT work. The tests still run with root, no password, db test. I have even put the MYSQL_... environment variables in my ~/.profile and opened a new shell but with the same results. I finally just modified the 'connect.inc' files (forcing my values) and the tests ran fine.

What am I missing? :(
vitantonio
New php-forum User
New php-forum User
 
Posts: 1
Joined: Fri Mar 21, 2014 6:00 am

Return to PHP Installation

Who is online

Users browsing this forum: No registered users and 1 guest

Sponsored by Sitebuilder Web hosting and Traduzioni Italiano Rumeno and antispam for cPanel.