Test resources added. Little refactoring