0

I am attempting to setup Codeception for the first time, however when I run run --debug I get a DB connection error, yet I cannot find where the configuration is to change this.

vagrant@localhost /var/www/crmpicco (confirmation)$ php vendor/codeception/codeception/codecept run --debug

Codeception PHP Testing Framework v1.9-dev Powered by PHPUnit 3.7.28 by Sebastian Bergmann.

[Codeception\Exception\Module] (Exception in Db) SQLSTATE[HY000] [1045] Access denied for user 'ubuntu'@'localhost' (using password: NO) while creating PDO connection

3
  • please post your db connection code. Commented Mar 4, 2015 at 10:37
  • @GaneshSalunkhe I'm not familiar with Codeception. I cannot locate the Codeception DB configuration. Where is that found in the codebase? Commented Mar 4, 2015 at 11:05
  • I think its because of user 'ubuntu'(which does not exists). You can add the 'ubuntu' user through phpmyadmin and give that user no privilege and it should work Commented Mar 4, 2015 at 11:09

1 Answer 1

1

I eventually found the credentials to resolve this in the following files:

  • tests/acceptance.suite.yml
  • tests/functional.suite.yml

    class_name: TestGuy modules: enabled: [REST, Db, ZF1, TestHelper, DbzHelper, GuzzleHelper]
    config: REST: timeout: 90 Db: dsn: 'mysql:host=10.0.0.200;dbname=crmpicco_test' user: 'vagrant' password: 'vagrant' dump: tests/_data/dump.sql populate: true cleanup: false ZF1: env: 'test' app_path: 'crmpicco/application' lib_path: 'library' config: 'crmpicco/application/configs/application.ini'

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.