mirror of
https://github.com/nodejs/node.git
synced 2025-05-06 05:21:19 +00:00

PR-URL: https://github.com/nodejs/node/pull/15935 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com> Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
15 lines
466 B
JavaScript
15 lines
466 B
JavaScript
'use strict';
|
|
const common = require('../../common');
|
|
const assert = require('assert');
|
|
|
|
// Testing api calls for arrays
|
|
const test_dataview = require(`./build/${common.buildType}/test_dataview`);
|
|
|
|
//create dataview
|
|
const buffer = new ArrayBuffer(128);
|
|
const template = Reflect.construct(DataView, [buffer]);
|
|
|
|
const theDataview = test_dataview.CreateDataView(template);
|
|
assert.ok(theDataview instanceof DataView,
|
|
`Expect ${theDataview} to be a DataView`);
|