[TYPO3-core] Contribution to TYPO3 v4 :: PHP unit tests (before pushing to gerrit)
Philipp Gampe
philipp.gampe at typo3.org
Tue Jun 12 20:19:31 CEST 2012
Hi Roland,
Roland wrote:
> i commited some CGL violation patches lately and would like to start
> unit testing the core before i push my commit to gerrit.
>
> what is the best way to do this?
>
> i (for testing purpose) just installed EXT:phpunit in a TYPO3 project
> (TYPO3 4.7.1) i work on and clicked on "run all tests" in it's backend
> module:
That is the preferred way to do it. TYPO3 needs bootstrapping and thus the
extension phpunit to run unit tests.
> --- quote ---
> 696 tests, 814 assertions, 11 failures, 31 skipped, 1 not implemented, 1
> errors, 12.565 seconds, 23 MB (23913832 B) memory leaks
> --- /quote ---
>
Much better than my results (master/typo3)
1718 tests, 2142 assertions, 52 failures, 107 skipped, 0 incomplete, 20
errors, 22.747 seconds, 42 MB (43755640 B) memory leaks
> there seems to exist tests which do not pass. is this ok? if so: does
> unit testing make sense before pushing to gerrit?
definitely makes sense. Just test what you changed.
> i went to ci.typo3.org and searched for phpunit test results? does
> jenkins execute the unit tests for TYPO3 v4 at the moment?
>
> ++ "Projekt typo3-v4-core-gerrit" only executes PHP syntax checks & 11
> codesniffer rules
>
> ++ "Projekt typo3-v4-core-nightly" executes PHP Lint, Codesniffer, PHP
> Copy and Paste detection and PHP Depend - but not PHP unit tests
>
> these 2 jobs are the only ones that are executed on a regular base.
That is sad, but some people are working on running them via travis+varnich.
Cheers
--
Philipp Gampe – PGP-Key 0AD96065 – TYPO3 UG Bonn/Köln
Documentation – linkvalidator
TYPO3 .... inspiring people to share!
More information about the TYPO3-team-core
mailing list