Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Update bootstrap.php so the tests can run on both HHVM and Zend #143

Closed
wants to merge 1 commit into from
Closed

Update bootstrap.php so the tests can run on both HHVM and Zend #143

wants to merge 1 commit into from

Conversation

JoelMarcey
Copy link
Contributor

PDOStatement does not have a direct constructor (i.e., __construct). Newing up a PDOStatement or subclass (e.g., MockPDOStatement) does technically work in Zend, but HHVM throws. A correct way to have the code currently structured in bootstrap.php work correctly on both Zend and HHVM is provide a default constructor and execute method in MockPDOStatement. It would probably best long term to avoid newing up a PDOStatement and create the queries another way. But this works for now.

PDOStatement does not have a direct constructor (i.e., __construct). Newing up a PDOStatement or subclass (e.g., MockPDOStatement) does technically work in Zend, but HHVM throws. A correct way to have the code currently structured in bootstrap.php work correctly on both Zend and HHVM is provide a default constructor and execute method in MockPDOStatement. It would probably best long term to avoid newing up a PDOStatement and create the queries another way. But this works for now.
@treffynnon
Copy link
Collaborator

Merged in commit 4e9f892

@treffynnon treffynnon closed this Aug 28, 2013
dmitrymomot pushed a commit to dmitrymomot/paris that referenced this pull request Apr 21, 2014
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants