Bug 143450

Summary: WebKit1.SetAndUpdateCacheModelPreferencesChangeMix fails on some machines
Product: WebKit Reporter: Alexey Proskuryakov <ap>
Component: Tools / TestsAssignee: Alexey Proskuryakov <ap>
Status: RESOLVED FIXED    
Severity: Normal CC: andersca, benjamin, commit-queue, thorton
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
proposed fix none

Description Alexey Proskuryakov 2015-04-06 12:05:08 PDT
The last subtest in WebKit1.SetAndUpdateCacheModelPreferencesChangeMix relies on the WebView to be deallocated/closed by webView.clear(). But this is not necessarily going to happen, because an autorelease pool can keep the view object alive until later.

    webView.clear();
    EXPECT_EQ((int)WebCacheModelDocumentViewer, (int)[WebView _cacheModel]); // <-- Only works when the above clear() drops the last reference.

Two ways to fix this:

1. Drain an autorelease pool before the check.

2. Call -close on the view explicitly.

I like the latter more, as it's the -close that we are actually after.
Comment 1 Alexey Proskuryakov 2015-04-06 12:07:39 PDT
Created attachment 250219 [details]
proposed fix
Comment 2 WebKit Commit Bot 2015-04-06 12:58:58 PDT
Comment on attachment 250219 [details]
proposed fix

Clearing flags on attachment: 250219

Committed r182434: <http://trac.webkit.org/changeset/182434>
Comment 3 WebKit Commit Bot 2015-04-06 12:59:02 PDT
All reviewed patches have been landed.  Closing bug.