Some refactoring of the browserchanneltest class to prepare the code for easier extraction