Bug 169663 - Make unit tests return a promise instead of manually calling done
Summary: Make unit tests return a promise instead of manually calling done
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Perf Dashboard (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Ryosuke Niwa
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-03-14 23:55 PDT by Ryosuke Niwa
Modified: 2017-03-15 11:16 PDT (History)
6 users (show)

See Also:


Attachments
Cleanup tests (62.15 KB, patch)
2017-03-14 23:59 PDT, Ryosuke Niwa
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ryosuke Niwa 2017-03-14 23:55:01 PDT
Make the existing unit tests always reutrn a promise instead of manually calling "done" callback.
The promise tests are a lot more stable and less error prone.

See ​https://bugs.webkit.org/show_bug.cgi?id=169648
Comment 1 Ryosuke Niwa 2017-03-14 23:59:06 PDT
Created attachment 304481 [details]
Cleanup tests
Comment 2 Antti Koivisto 2017-03-15 05:37:31 PDT
Comment on attachment 304481 [details]
Cleanup tests

Could some of these then() cascades be replaced with await?
Comment 3 Ryosuke Niwa 2017-03-15 10:37:13 PDT
(In reply to comment #2)
> Comment on attachment 304481 [details]
> Cleanup tests
> 
> Could some of these then() cascades be replaced with await?

Unfortunately not yet since the stable version of node doesn't support it yet.
Comment 4 WebKit Commit Bot 2017-03-15 11:15:50 PDT
Comment on attachment 304481 [details]
Cleanup tests

Clearing flags on attachment: 304481

Committed r213993: <http://trac.webkit.org/changeset/213993>
Comment 5 WebKit Commit Bot 2017-03-15 11:16:03 PDT
All reviewed patches have been landed.  Closing bug.