some refactoring on the blackbox tests