blob: 11c6a8f7ef21a7db38b3c5e3fb93f916a9719711 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
// META: title=validation tests for WebNN API pad operation
// META: global=window,dedicatedworker
// META: script=../resources/utils_validation.js
'use strict';
multi_builder_test(async (t, builder, otherBuilder) => {
const inputFromOtherBuilder =
otherBuilder.input('input', {dataType: 'float32', dimensions: [2, 2]});
const beginningPadding = [1, 1];
const endingPadding = [1, 1];
assert_throws_js(
TypeError,
() =>
builder.pad(inputFromOtherBuilder, beginningPadding, endingPadding));
}, '[pad] throw if input is from another builder');
|