Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

fix: resolve issue with xdebug.mode not being set #346

Closed
wants to merge 1 commit into from

Conversation

owenvoke
Copy link
Contributor

@owenvoke owenvoke commented Nov 26, 2020

Related discussion: pestphp/pest#226

Description

When using coverage: xdebug on macOS and Windows (Linux correctly uses Xdebug 2 for now on PHP <=7.4), it appears to fail on PHP 7.x as Xdebug 3 is being installed, rather than Xdebug 2.x. As this bit of code is expecting for coverage: xdebug3 or PHP 8 to add the xdebug.mode=coverage line, this never gets set.

I've created some workflows that tested against all PHP versions back to 5.3, and their compatible PHPUnit version.

On the current version, PHPUnit flags a warning that xdebug.mode=coverage has to be set in php.ini. I'm also not sure why XDEBUG_CC_UNUSED is undefined on PHP 7.2 for macOS and Windows.

In case this PR introduced TypeScript/JavaScript code changes:

  • I have written test cases for the changes in this pull request
  • I have run npm run format before the commit.
  • I have run npm run lint before the commit.
  • I have run npm run release before the commit.
  • npm test returns with no unit test errors and all code covered.

In case this PR edits any scripts:

  • I have checked the edited scripts for syntax.
  • I have tested the changes in an integration test (If yes, provide workflow YAML and link).

@owenvoke owenvoke closed this Nov 26, 2020
@owenvoke
Copy link
Contributor Author

Just noticed you've already committed changes to this effect. 👍🏻 fce77af

Thanks @shivammathur for all your work on this.

@owenvoke owenvoke deleted the bugfix/xdebug-3 branch November 26, 2020 17:09
@shivammathur
Copy link
Owner

@owenvoke Thanks for testing this, fix will be in next release shortly.

@shivammathur shivammathur mentioned this pull request Nov 26, 2020
@shivammathur
Copy link
Owner

@owenvoke Merged in 2.9.0 and the issue should be fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants