On 3/25/19 11:22 AM, violet.bugrep...@gmail.com wrote:
I think it should be a browser test, because I need to call IndexedDB.

OK, makes sense.

In that case, the simplest option is to pick a browser test that involves Xray wrappers and modify it so you have an Xray to an ArrayBufferView.

If IndexedDB works in system-principal pages, you could take something like https://searchfox.org/mozilla-central/source/js/xpconnect/tests/chrome/test_xrayToJS.xul and use a similar setup. So create a mochitest-chrome test that loads file_empty.html or equivalent in a subframe, then do:

var view = new (document.getElementById('ifr').contentWindow.Int32Array)(5);

or so and go on from there.

If you run into trouble, please feel free to ping me on IRC ("bz" on #content or #developers) or mail me, or post here.

-Boris
_______________________________________________
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform

Reply via email to