[TYPO3-core] Integrate base test classe(s) of tx_phpunit into the core?

Helmut Hummel helmut.hummel at typo3.org
Wed Jun 27 15:39:20 CEST 2012


Hi Oli,

Am 27.06.12 12:44, schrieb Oliver Klee:

> I do not have any objections to having the base test class
> Tx_Phpunit_TestCase as part of the core. (Anyway, the class is no rocket
> science either - it just sets $backupGlobals and $backupStaticAttributes
> and provides the methods getAccessibleMock and buildAccessibleProxy).

OK, check. We do that.

> However, moving/copying the helper classes (TestFinder and the Testing
> Framework) from the phpunit extension to the Core will not be easy as
> those classes depend on lots of other classes from the phpunit
> extension. In addition, we should be aware of the fact that the
> TestFinder class not only is responsible for finding locating the Core
> test cases, but also of locating the test cases of extensions.

I did not have a closer look into what the TestFinder does and what 
other parts of the phpunit extensions the core tests rely on. I'd like 
to check what is really mandatory and what is optional.

I'm also not aware of anything else than the TestFinder and the base 
class, which is used in the core tests.

> I think that currently the most logic place for those helper classes is
> inside the phpunit extension. (I'm using the the following logic here:
> "Where would I first look for those classes?")

I still think however, that the core should deliver everything that is 
needed for it's own tests. Not the PHPUnit pear package, but at least 
all configuration and necessary classes.

> However, I
> currently wouldn't consider the phpunit extension to be save for sites
> that are reachable from the internet: Big parts of the extension still
> are quite a mess (which I'm working on cleaning up), and some things
> might not be secure enough (yet) for this.

As I wrote above: I only want to include the least necessary.

Since we seem to agree in general, I will come up with a review request 
for the core soon.

> About having the Core unit test results in the reports module:
> Currently, I don't consider the unit tests to be fast enough for a quick
> feedback in that module (and don't expect them to be so anytime soon).
> We need some other place for this.

Agreed. Would be nice if they could be easily executed from the command 
line though, but that is not that important.

Kind regards,
Helmut

-- 
Helmut Hummel
Release Manager TYPO3 6.0
TYPO3 Core Developer, TYPO3 Security Team Leader

TYPO3 .... inspiring people to share!
Get involved: typo3.org


More information about the TYPO3-team-core mailing list