Bug 898378 - Correctly close the opened context menu in testExpectedEvents.js. r=hskupin