Adding a testing framework to IP

Hi,

Working on the v1.6.0 branch, I realize that if this project will go forward we definitely need a testing framework, to assert calculations on invoices at least.

Php is messy enough and some parts of the code lack structure, which can make fixing problems confusing at times. We need to keep an eye on effect-propagation.

I’m not up to date in the Php world but can this be the one?
https://phpunit.de/

I think if someone has free time and wants to improve the project,
this will be very useful, I can contribute with the tests for my part in the invoice calculation.

Consider I don’t have much free time in this period of time.

Tell me what you think.
@Martin_Anonym @clockwiseq @UnderDog

Thanks in advance.

3 Likes

I think this is a good idea, I will do soem researches about what testing frameworks we could use and will report back. But PHPUnit is a good point to start.

2 Likes

Ok,
I’ll hand this to you

Good coverage of tests is what we need, this will realistically happen over time, as we need to write better testable code, but setting this up is a first good step.

If someone has an effort to give, this is a good direction to go.

2 Likes

I agree. Automated unit testing are essential to a solid release cycle and improves the overall quality of the product. Thanks for finding this @Luca_Pellizzari and we will see what we can do about implementing something such as PHPUnit.

1 Like

I asked about this once with the view of using codeception.

I started a branch with the codeception setup and some minor tests. Think I’ll upgrade and merge my branch.

2 Likes