Pooja: minor refactoring in tests