Commit 5c8d3722 authored by Luke Bjerring's avatar Luke Bjerring Committed by Commit Bot

[idlharness.js] Add main interface as dep for implements

Case was revealed by https://github.com/web-platform-tests/wpt/pull/9794
Specifically, Navigator implements NavigatorUserMedia;

Navigator was not being added as a depenedency, and thus was not being imported.

Change-Id: I07436c561bb0b567a431393a20f6a179ef5b364b
Reviewed-on: https://chromium-review.googlesource.com/1104707Reviewed-by: default avatarRobert Ma <robertma@chromium.org>
Commit-Queue: Luke Bj <lukebjerring@chromium.org>
Cr-Commit-Position: refs/heads/master@{#568143}
parent 6d73bac5
...@@ -257,7 +257,10 @@ IdlArray.prototype.add_dependency_idls = function(raw_idls, options) ...@@ -257,7 +257,10 @@ IdlArray.prototype.add_dependency_idls = function(raw_idls, options)
const all_deps = new Set(); const all_deps = new Set();
Object.values(this.inheritance).forEach(v => all_deps.add(v)); Object.values(this.inheritance).forEach(v => all_deps.add(v));
Object.values(this.implements).forEach(v => all_deps.add(v)); Object.entries(this.implements).forEach(([k, v]) => {
all_deps.add(k);
all_deps.add(v);
});
// NOTE: If 'A includes B' for B that we care about, then A is also a dep. // NOTE: If 'A includes B' for B that we care about, then A is also a dep.
Object.keys(this.includes).forEach(k => { Object.keys(this.includes).forEach(k => {
all_deps.add(k); all_deps.add(k);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment