Bug 989374: Consolidate logic from browser_dbg_addon-* tests. r=fitzgen