iframe.cross-origin.https.window.js (1164B)
1 // META: script=/common/get-host-info.sub.js 2 // META: script=./resources/checker.js 3 // META: script=./resources/common.js 4 // META: timeout=long 5 'use strict'; 6 7 promise_test(async testCase => { 8 assert_true(self.crossOriginIsolated); 9 10 const {iframes, windows} = await build([ 11 { 12 id: 'cross-origin-1', 13 children: [ 14 { 15 id: 'same-origin-2', 16 }, 17 { 18 id: 'cross-origin-3', 19 }, 20 { 21 id: 'cross-site-4', 22 } 23 ], 24 }, 25 ]); 26 const result = await performance.measureUserAgentSpecificMemory(); 27 checkMeasureMemory(result, [ 28 { 29 url: window.location.href, 30 scope: 'Window', 31 container: null, 32 }, 33 { 34 url: 'cross-origin-url', 35 scope: 'cross-origin-aggregated', 36 container: { 37 id: 'cross-origin-1', 38 src: iframes['cross-origin-1'].src, 39 }, 40 }, 41 { 42 url: windows['same-origin-2'].location.href, 43 scope: 'Window', 44 container: { 45 id: 'cross-origin-1', 46 src: iframes['cross-origin-1'].src, 47 }, 48 }, 49 ]); 50 }, 'performance.measureUserAgentSpecificMemory URLs within a cross-origin iframe.');