-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathno_ra.rs
58 lines (54 loc) · 1.39 KB
/
no_ra.rs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
mod common;
use anyhow::Result;
use common::{run_test, task::app::AppType};
/// both tng client and tng server are in non-tee env
#[tokio::test(flavor = "multi_thread", worker_threads = 10)]
async fn test() -> Result<()> {
run_test(
&AppType::TcpServer { port: 30001 },
&AppType::TcpClient {
host: "127.0.0.1",
port: 10001,
http_proxy: None,
},
r#"
{
"add_egress": [
{
"mapping": {
"in": {
"host": "127.0.0.1",
"port": 20001
},
"out": {
"host": "127.0.0.1",
"port": 30001
}
},
"no_ra": true
}
]
}
"#,
r#"
{
"add_ingress": [
{
"mapping": {
"in": {
"port": 10001
},
"out": {
"host": "127.0.0.1",
"port": 20001
}
},
"no_ra": true
}
]
}
"#,
)
.await?;
Ok(())
}