Code for the egghead.io video Detecting Console Errors in Protractor Tests