/
githubmirror
/
deno
Обзор
Документация
Войти
/
githubmirror
/
deno
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
tests/napi/array_test.js
19 строк
528 B
Kenta Moriuchi
chore: Happy New Year 2026 (#31748)
08 янв 2026, 18:28
Не верифицирован
08 янв 2026, 18:28
8193cf9
Код
Авторство
О чём код?
// Copyright 2018-2026 the Deno authors. MIT license. import { assertEquals, loadTestLibrary } from "./common.js"; const array = loadTestLibrary(); Deno.test("napi array new", function () { const e = [0, "Hello", {}]; const r = array.test_array_new(e); assertEquals(typeof r, "object"); assertEquals(r.length, 3); assertEquals(e, r); }); Deno.test("napi array new with length", function () { const r = array.test_array_new_with_length(100); assertEquals(typeof r, "object"); assertEquals(r.length, 100); });