Skip to content

Commit 37138a2

Browse files
committed
fix: update traversal test assertion to match new error message
The test_validate_workspace_path_prevents_traversal test now also accepts the 'must not contain ..' error message from the early rejection check.
1 parent 67a0aac commit 37138a2

File tree

1 file changed

+3
-1
lines changed
  • src-tauri/src/extensions/wasm

1 file changed

+3
-1
lines changed

src-tauri/src/extensions/wasm/host.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1316,7 +1316,9 @@ mod tests {
13161316

13171317
let err_msg = result.unwrap_err();
13181318
assert!(
1319-
err_msg.contains("escapes workspace root") || err_msg.contains("Invalid"),
1319+
err_msg.contains("escapes workspace root")
1320+
|| err_msg.contains("Invalid")
1321+
|| err_msg.contains("must not contain '..'"),
13201322
"Error should mention path escape: {}",
13211323
err_msg
13221324
);

0 commit comments

Comments
 (0)