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

Document changes made to the Test class for NC11 #2135

Closed
oparoz opened this issue Nov 15, 2016 · 6 comments
Closed

Document changes made to the Test class for NC11 #2135

oparoz opened this issue Nov 15, 2016 · 6 comments
Labels

Comments

@oparoz
Copy link
Member

oparoz commented Nov 15, 2016

There have been breaking changes made to the Test class and devs need:

  1. To be made aware of it
  2. Ideally to be told how to adapt their code

cc @rullzer @nickvergessen @LukasReschke , but feel free to share with others ;)

@oparoz oparoz added the bug label Nov 15, 2016
@oparoz oparoz added this to the Nextcloud 11.0 milestone Nov 15, 2016
@oparoz
Copy link
Member Author

oparoz commented Nov 15, 2016

Sample of the breakage which happens after the changes on PHP 7:

[PHPUnit_Framework_Exception]                                                                                                                  
  Declaration of Test\TestCase::onNotSuccessfulTest($e) should be compatible with PHPUnit_Framework_TestCase::onNotSuccessfulTest(Exception $e)  

@nickvergessen
Copy link
Member

The actual change is that since we now require php 5.6+ we also require phpunit 5+
Seems like travis doesn't have this: Powered by PHPUnit 4.8.26

@oparoz
Copy link
Member Author

oparoz commented Nov 15, 2016

Actually, that's the exact version being used:

3.48s$ php vendor/bin/codecept run acceptance --env firefox
Codeception PHP Testing Framework v2.2.1
Powered by PHPUnit 4.8.26 by Sebastian Bergmann and contributors.

  [PHPUnit_Framework_Exception]                                                                                                                  
  Declaration of Test\TestCase::onNotSuccessfulTest($e) should be compatible with PHPUnit_Framework_TestCase::onNotSuccessfulTest(Exception $e)

@oparoz
Copy link
Member Author

oparoz commented Nov 15, 2016

OK, after re-reading this, I guess it's a problem with PHPUnit which will never be fixed.

sebastianbergmann commented on 12 Feb
I do not support PHPUnit 4.8 on PHP 7, as is clearly stated on the website.

Since PHPUnit 5 still support 5.6. There should be a note somewhere about that change so that all app devs can update their Travis.

@nickvergessen
Copy link
Member

I added 100 lines of magic to fix it: #2137

@oparoz
Copy link
Member Author

oparoz commented Nov 15, 2016

Great, thanks!. Let's close this then if that was the only problem linked to PHP 5.6 and testing.

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

No branches or pull requests

2 participants