[astute] Improve a consistency of a dir-based logparser tests.

Avoid a deletion of temp objects by keeping a reference to them.