Unittest error


I've got a little problem with my unit tests. I need to initialize some variables in my test class. I do it in my setUp() function. Of course i do a parent::setUp() in it.

I've got 2 function in my test class. The first is ok, and when it execute the second i've got this error : "Service 'db' was not found in the dependency injection container"

It seems like DI is completly reset or something! Any ideas on the subject ?


could please post your code snippet here?

have you make sure register 'db' in DI?