some more code cleaning on bb test lib