summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/integration/jupyter_tests.rs10
-rw-r--r--tests/specs/jupyter/install_command/__test__.jsonc (renamed from tests/specs/jupyter/install_command_not_exists/__test__.jsonc)4
-rw-r--r--tests/specs/jupyter/install_command/install_command.out2
-rw-r--r--tests/specs/jupyter/install_command_not_exists/install_command_not_exists.out5
4 files changed, 10 insertions, 11 deletions
diff --git a/tests/integration/jupyter_tests.rs b/tests/integration/jupyter_tests.rs
index 3c4efbdac..c7b2712e8 100644
--- a/tests/integration/jupyter_tests.rs
+++ b/tests/integration/jupyter_tests.rs
@@ -10,6 +10,8 @@ use test_util::DenoChild;
use test_util::TestContext;
use test_util::TestContextBuilder;
+use chrono::DateTime;
+use chrono::Utc;
use deno_core::anyhow::Result;
use deno_core::serde_json;
use deno_core::serde_json::json;
@@ -119,7 +121,7 @@ impl Default for JupyterMsg {
struct MsgHeader {
msg_id: Uuid,
session: Uuid,
- date: String,
+ date: DateTime<Utc>,
username: String,
msg_type: String,
version: String,
@@ -136,7 +138,7 @@ impl Default for MsgHeader {
Self {
msg_id: Uuid::new_v4(),
session: Uuid::new_v4(),
- date: utc_now().to_rfc3339(),
+ date: utc_now(),
username: "test".into(),
msg_type: "kernel_info_request".into(),
version: "5.3".into(),
@@ -517,7 +519,7 @@ async fn jupyter_kernel_info() -> Result<()> {
"mimetype": "text/x.typescript",
"file_extension": ".ts",
"pygments_lexer": "typescript",
- "nb_converter": "script"
+ "nbconvert_exporter": "script"
},
}),
);
@@ -612,7 +614,7 @@ async fn jupyter_store_history_false() -> Result<()> {
json!({
"silent": false,
"store_history": false,
- "code": "console.log(\"asdf\")"
+ "code": "console.log(\"asdf\")",
}),
)
.await?;
diff --git a/tests/specs/jupyter/install_command_not_exists/__test__.jsonc b/tests/specs/jupyter/install_command/__test__.jsonc
index 9552157bd..df60c3b86 100644
--- a/tests/specs/jupyter/install_command_not_exists/__test__.jsonc
+++ b/tests/specs/jupyter/install_command/__test__.jsonc
@@ -1,8 +1,8 @@
{
"args": "jupyter --install",
- "output": "install_command_not_exists.out",
+ "output": "install_command.out",
"envs": {
"PATH": ""
},
- "exitCode": 1
+ "exitCode": 0
}
diff --git a/tests/specs/jupyter/install_command/install_command.out b/tests/specs/jupyter/install_command/install_command.out
new file mode 100644
index 000000000..62875d9cf
--- /dev/null
+++ b/tests/specs/jupyter/install_command/install_command.out
@@ -0,0 +1,2 @@
+Warning "deno jupyter" is unstable and might change in the future.
+✅ Deno kernelspec installed successfully.
diff --git a/tests/specs/jupyter/install_command_not_exists/install_command_not_exists.out b/tests/specs/jupyter/install_command_not_exists/install_command_not_exists.out
deleted file mode 100644
index 1bb176e20..000000000
--- a/tests/specs/jupyter/install_command_not_exists/install_command_not_exists.out
+++ /dev/null
@@ -1,5 +0,0 @@
-Warning "deno jupyter" is unstable and might change in the future.
-error: Failed to spawn 'jupyter' command. Is JupyterLab installed (https://jupyter.org/install) and available on the PATH?
-
-Caused by:
-[WILDCARD]