[TYPO3-core] RFC #15020: Enhancement of t3lib_div::testInt

Dmitry Dulepov dmitry at typo3.org
Wed Jul 7 15:02:40 CEST 2010


Hi!

Jigal van Hemert wrote:
> Maybe we should require unit tests for changes in core functions?

Theoretically – yes, practically how would you test "version" part of
t3lib_tcemain::process_cmdmap()? It is too complex...

> If a function is changed and the first unit test is provided the unit
> test can get a thorough look to make sure it includes enough test cases
> to cover the possible input and output.
> 
> Future reviews of changes would be a lot simpler.

I agree! We should definitely have that for smaller functions. We even need
to refactor monsters like process_cmdmap() and process_datamap() into
testable functions.

-- 
Dmitry Dulepov
TYPO3 core&security teams member
Twitter: http://twitter.com/dmitryd
Read more @ http://dmitry-dulepov.com/


More information about the TYPO3-team-core mailing list