blob: f616203a88b5f716e4c2e646049c641db3aef3dc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
// META: title=validation tests for WebNN API cast 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: 'int32', dimensions: [2, 2]});
assert_throws_js(
TypeError, () => builder.cast(inputFromOtherBuilder, 'int64'));
}, '[cast] throw if input is from another builder');
|