diff options
Diffstat (limited to 'cli')
-rw-r--r-- | cli/bench/napi/bench.js | 2 | ||||
-rw-r--r-- | cli/bench/napi/bench_node.mjs | 2 | ||||
-rw-r--r-- | cli/napi/README.md | 10 |
3 files changed, 7 insertions, 7 deletions
diff --git a/cli/bench/napi/bench.js b/cli/bench/napi/bench.js index d2aac63df..c12c7aacb 100644 --- a/cli/bench/napi/bench.js +++ b/cli/bench/napi/bench.js @@ -1,6 +1,6 @@ // Copyright 2018-2024 the Deno authors. All rights reserved. MIT license. -import { loadTestLibrary } from "../../../test_napi/common.js"; +import { loadTestLibrary } from "../../../tests/napi/common.js"; const lib = loadTestLibrary(); diff --git a/cli/bench/napi/bench_node.mjs b/cli/bench/napi/bench_node.mjs index 2593aadd2..82e06f08f 100644 --- a/cli/bench/napi/bench_node.mjs +++ b/cli/bench/napi/bench_node.mjs @@ -2,7 +2,7 @@ import { bench, run } from "mitata"; import { createRequire } from "module"; const require = createRequire(import.meta.url); -const lib = require("../../../test_napi.node"); +const lib = require("../../../tests/napi.node"); bench("warmup", () => {}); bench("napi_get_undefined", () => lib.test_get_undefined(0)); diff --git a/cli/napi/README.md b/cli/napi/README.md index e40d4719d..ec637e1bd 100644 --- a/cli/napi/README.md +++ b/cli/napi/README.md @@ -50,11 +50,11 @@ Update the generated symbol lists using the script: deno run --allow-write tools/napi/generate_symbols_lists.js ``` -Add a test in [`/test_napi`](../../test_napi/). You can also refer to Node.js +Add a test in [`/tests/napi`](../../tests/napi/). You can also refer to Node.js test suite for Node-API. ```js -// test_napi/boolean_test.js +// tests/napi/boolean_test.js import { assertEquals, loadTestLibrary } from "./common.js"; const lib = loadTestLibrary(); Deno.test("napi get boolean", function () { @@ -64,7 +64,7 @@ Deno.test("napi get boolean", function () { ``` ```rust -// test_napi/src/boolean.rs +// tests/napi/src/boolean.rs use napi_sys::Status::napi_ok; use napi_sys::ValueType::napi_boolean; @@ -96,7 +96,7 @@ pub fn init(env: napi_env, exports: napi_value) { ``` ```diff -// test_napi/src/lib.rs +// tests/napi/src/lib.rs + mod boolean; @@ -114,4 +114,4 @@ unsafe extern "C" fn napi_register_module_v1( } ``` -Run the test using `cargo test -p test_napi`. +Run the test using `cargo test -p tests/napi`. |