Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions tng-testsuite/tests/hook/ingress_hook_capture_local_traffic.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ async fn test() -> Result<()> {
name: "echo server on loopback".to_owned(),
node_type: NodeType::Client,
script: r#"
set -euo pipefail

python3 -c '
import socket, threading, time
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
Expand All @@ -60,6 +62,16 @@ sleep 120
mode: ShellMode::BackgroundContinue,
}
.boxed(),
ShellTask {
name: "sleep a bit for echo server to start".to_owned(),
node_type: NodeType::Client,
script: r#"
sleep 3
"#
.to_owned(),
mode: ShellMode::ForegroundContinue,
}
.boxed(),
// Client side: tng exec with ingress hook.
// capture_dst: [{"port": 20001}] with NO capture_local_traffic field -> defaults to false.
//
Expand Down
Loading