Closed andreiashu closed 11 years ago
did you consider performances of running drupal_static_reset
before each single test?
additionally, to me this does not belong to WebTestCase but to DrupalTestCase.
finally, since this code uses the LiipDrupalConnector, the call to drupal_static_reset
should also be wrapped through it.
@sixty-nine very good point about drupal_static_reset having to be wrapped. I'll investigate the point about DrupalTC vs WebTC as well.
Re performance: I haven't profiled it but I think the performance implications of calling this function are outweighed by enforcing isolation between tests (see also #5)
I took the liberty to move your code to DrupalTestCase. The reason is that WebTestCase does actually not contain anything related to Drupal. Theoretically WebTC could be used outside of a Drupal project.
Furthermore I wrapped the call to drupal_static_reset in the DrupalConnector class to follow the conventions of the rest of the code.
Thank you for your contribution.
Thx Andreas!