{"action":"created","issue":{"url":"https://api.github.com/repos/GoogleChrome/lighthouse/issues/212","repository_url":"https://api.github.com/repos/GoogleChrome/lighthouse","labels_url":"https://api.github.com/repos/GoogleChrome/lighthouse/issues/212/labels{/name}","comments_url":"https://api.github.com/repos/GoogleChrome/lighthouse/issues/212/comments","events_url":"https://api.github.com/repos/GoogleChrome/lighthouse/issues/212/events","html_url":"https://github.com/GoogleChrome/lighthouse/pull/212","id":149574011,"number":212,"title":"reorganization of devtools frontend imports and mocking","user":{"login":"brendankenny","id":316891,"avatar_url":"https://avatars.githubusercontent.com/u/316891?v=3","gravatar_id":"","url":"https://api.github.com/users/brendankenny","html_url":"https://github.com/brendankenny","followers_url":"https://api.github.com/users/brendankenny/followers","following_url":"https://api.github.com/users/brendankenny/following{/other_user}","gists_url":"https://api.github.com/users/brendankenny/gists{/gist_id}","starred_url":"https://api.github.com/users/brendankenny/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/brendankenny/subscriptions","organizations_url":"https://api.github.com/users/brendankenny/orgs","repos_url":"https://api.github.com/users/brendankenny/repos","events_url":"https://api.github.com/users/brendankenny/events{/privacy}","received_events_url":"https://api.github.com/users/brendankenny/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/GoogleChrome/lighthouse/labels/+1","name":"+1","color":"5319e7"},{"url":"https://api.github.com/repos/GoogleChrome/lighthouse/labels/+2","name":"+2","color":"bfe5bf"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2016-04-19T20:27:15Z","updated_at":"2016-04-20T20:51:31Z","closed_at":"2016-04-20T20:51:20Z","pull_request":{"url":"https://api.github.com/repos/GoogleChrome/lighthouse/pulls/212","html_url":"https://github.com/GoogleChrome/lighthouse/pull/212","diff_url":"https://github.com/GoogleChrome/lighthouse/pull/212.diff","patch_url":"https://github.com/GoogleChrome/lighthouse/pull/212.patch"},"body":"followup to #190 \r\n\r\n- require `WebInspector` into `devtools-timeline-model.js`\r\n- some rearranging within `web-inspector.js` to make imports and stubbing out more explicit. This involved pulling in contents of `devtools-monkeypatches.js` and `api-stubs.js` directly instead of requiring them from `devtools-timeline-model` to keep things a little more sane. Some of the mocked APIs were getting redefined up to four times by us (e.g. `WebInspector.moduleSetting`) and their final value depended on the order in which the mocking files were called over the entirety of lighthouse since `WebInspector` lives in the global scope. We also get some nice things out of this like a single spot to enable/disable `Runtime.experiments`.\r\n\r\nSome changes we may want to upstream to `devtools-timeline-model`, but conflicts seem inevitable since lighthouse needs quite a few more things stubbed out than just the timeline-related stuff."},"comment":{"url":"https://api.github.com/repos/GoogleChrome/lighthouse/issues/comments/212601762","html_url":"https://github.com/GoogleChrome/lighthouse/pull/212#issuecomment-212601762","issue_url":"https://api.github.com/repos/GoogleChrome/lighthouse/issues/212","id":212601762,"user":{"login":"paulirish","id":39191,"avatar_url":"https://avatars.githubusercontent.com/u/39191?v=3","gravatar_id":"","url":"https://api.github.com/users/paulirish","html_url":"https://github.com/paulirish","followers_url":"https://api.github.com/users/paulirish/followers","following_url":"https://api.github.com/users/paulirish/following{/other_user}","gists_url":"https://api.github.com/users/paulirish/gists{/gist_id}","starred_url":"https://api.github.com/users/paulirish/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paulirish/subscriptions","organizations_url":"https://api.github.com/users/paulirish/orgs","repos_url":"https://api.github.com/users/paulirish/repos","events_url":"https://api.github.com/users/paulirish/events{/privacy}","received_events_url":"https://api.github.com/users/paulirish/received_events","type":"User","site_admin":false},"created_at":"2016-04-20T20:51:31Z","updated_at":"2016-04-20T20:51:31Z","body":"baller. "}}