From d6f789eb05e18dd8887e8e409736773bdf2e0e00 Mon Sep 17 00:00:00 2001 From: David Sherret Date: Tue, 9 Aug 2022 17:28:13 -0400 Subject: [PATCH] chore: temporarily disable `op_require_read_file` (#15433) --- cli/tests/integration/compat_tests.rs | 1 + ext/node/01_require.js | 2 +- ext/node/lib.rs | 5 ++--- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cli/tests/integration/compat_tests.rs b/cli/tests/integration/compat_tests.rs index e8e6316bff..88514832fd 100644 --- a/cli/tests/integration/compat_tests.rs +++ b/cli/tests/integration/compat_tests.rs @@ -173,6 +173,7 @@ fn native_modules_as_global_vars() { assert!(out.contains("true")); } +#[ignore] // todo(dsherret): re-enable #[test] fn ext_node_cjs_execution() { let (out, _err) = util::run_and_collect_output_with_args( diff --git a/ext/node/01_require.js b/ext/node/01_require.js index 5a29617b1a..7b89e9dc37 100644 --- a/ext/node/01_require.js +++ b/ext/node/01_require.js @@ -476,7 +476,7 @@ if (typeof options === "object" && options !== null) { if (ArrayIsArray(options.paths)) { const isRelative = core.opSync( - "op_require_specifier_is_relative", + "op_require_is_request_relative", request, ); diff --git a/ext/node/lib.rs b/ext/node/lib.rs index 5d6542dc53..80296a6cc2 100644 --- a/ext/node/lib.rs +++ b/ext/node/lib.rs @@ -311,7 +311,6 @@ fn op_require_try_self( } #[op] -fn op_require_read_file(filename: String) -> Result { - let contents = std::fs::read_to_string(filename)?; - Ok(contents) +fn op_require_read_file(_filename: String) -> Result { + todo!("not implemented"); }