summaryrefslogtreecommitdiffstats
path: root/src/tests
diff options
context:
space:
mode:
Diffstat (limited to 'src/tests')
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_only_processes.snap5
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_processes_with_dns_queries.snap5
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_startup.snap5
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__bi_directional_traffic.snap29
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-full-width-under-30-height-draw_events.snap33
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-120-width-full-height-draw_events.snap32
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-120-width-under-30-height-draw_events.snap33
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-50-width-under-50-height-draw_events.snap22
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-70-width-under-30-height-draw_events.snap25
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__multiple_connections_from_remote_address.snap28
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__multiple_packets_of_traffic_from_different_connections.snap30
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__multiple_packets_of_traffic_from_single_connection.snap29
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__multiple_processes_with_multiple_connections.snap32
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__no_resolve_mode.snap30
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__one_packet_of_traffic.snap29
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__one_process_with_multiple_connections.snap28
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__pause_by_space.snap53
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__rearranged_by_tab.snap35
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__sustained_traffic_from_multiple_processes.snap30
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__sustained_traffic_from_multiple_processes_bi_directional.snap30
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__sustained_traffic_from_multiple_processes_bi_directional_total.snap30
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__sustained_traffic_from_multiple_processes_total.snap30
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__sustained_traffic_from_one_process.snap29
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__sustained_traffic_from_one_process_total.snap29
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__traffic_with_host_names.snap30
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__traffic_with_winch_event.snap55
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__truncate_long_hostnames.snap30
-rw-r--r--src/tests/cases/snapshots/bandwhich__tests__cases__ui__two_packets_only_processes.snap51
-rw-r--r--src/tests/fakes/fake_input.rs15
29 files changed, 102 insertions, 740 deletions
diff --git a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_only_processes.snap b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_only_processes.snap
index 1910f6a..7eebb2f 100644
--- a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_only_processes.snap
+++ b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_only_processes.snap
@@ -4,7 +4,7 @@ expression: terminal_draw_events.lock().unwrap().join(SNAPSHOT_SECTION_SEPARATOR
---
IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
┌Utilization by process name─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
-│Process Connections Rate (Up / Down) │
+│Process PID Connections Rate (Up / Down) │
│ │
│ │
│ │
@@ -51,5 +51,4 @@ IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
│ │
│ │
└────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
- Press <SPACE> to pause. Use <TAB> to rearrange tables. (DNS queries hidden).
-
+ Press <SPACE> to pause. Use <TAB> to rearrange tables. (DNS queries hidden).
diff --git a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_processes_with_dns_queries.snap b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_processes_with_dns_queries.snap
index 7fea434..952d8fe 100644
--- a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_processes_with_dns_queries.snap
+++ b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_processes_with_dns_queries.snap
@@ -4,7 +4,7 @@ expression: terminal_draw_events.lock().unwrap().join(SNAPSHOT_SECTION_SEPARATOR
---
IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
┌Utilization by process name─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐
-│Process Connections Rate (Up / Down) │
+│Process PID Connections Rate (Up / Down) │
│ │
│ │
│ │
@@ -51,5 +51,4 @@ IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
│ │
│ │
└────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
- Press <SPACE> to pause. Use <TAB> to rearrange tables. (DNS queries shown).
-
+ Press <SPACE> to pause. Use <TAB> to rearrange tables. (DNS queries shown).
diff --git a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_startup.snap b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_startup.snap
index f8c72d4..c34cf3b 100644
--- a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_startup.snap
+++ b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__basic_startup.snap
@@ -4,7 +4,7 @@ expression: terminal_draw_events.lock().unwrap().join(SNAPSHOT_SECTION_SEPARATOR
---
IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
┌Utilization by process name──────────────────────────────────────────────────────────────────┐┌Utilization by remote address────────────────────────────────────────────────────────────────┐
-│Process Connections Rate (Up / Down) ││Remote Address Connections Rate (Up / Down) │
+│Process PID Connections Rate (Up / Down) ││Remote Address Connections Rate (Up / Down) │
│ ││ │
│ ││ │
│ ││ │
@@ -51,5 +51,4 @@ IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
│ │
│ │
└────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
- Press <SPACE> to pause. Use <TAB> to rearrange tables. (DNS queries hidden).
-
+ Press <SPACE> to pause. Use <TAB> to rearrange tables. (DNS queries hidden).
diff --git a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__bi_directional_traffic.snap b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__bi_directional_traffic.snap
index 68295bf..426ac08 100644
--- a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__bi_directional_traffic.snap
+++ b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__bi_directional_traffic.snap
@@ -4,7 +4,7 @@ expression: terminal_draw_events.lock().unwrap().join(SNAPSHOT_SECTION_SEPARATOR
---
IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
┌Utilization by process name──────────────────────────────────────────────────────────────────┐┌Utilization by remote address────────────────────────────────────────────────────────────────┐
-│Process Connections Rate (Up / Down) ││Remote Address Connections Rate (Up / Down) │
+│Process PID Connections Rate (Up / Down) ││Remote Address Connections Rate (Up / Down) │
│ ││ │
│ ││ │
│ ││ │
@@ -57,7 +57,7 @@ IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
24. 0B / 25.00B
- 1 1 24.00B / 25.00B 1.1.1.1 1 24.00B / 25.00B
+ 1 1 1 24.00B / 25.00B 1.1.1.1 1 24.00B / 25.00B
@@ -81,27 +81,4 @@ IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
- <interface_name>:443 => 1.1.1.1:12345 (tcp) 1 24.00B / 25.00B
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ <interface_name>:443 => 1.1.1.1:12345 (tcp) 1 24.00B / 25.00B
diff --git a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-full-width-under-30-height-draw_events.snap b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-full-width-under-30-height-draw_events.snap
index 809920d..f2a0e8a 100644
--- a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-full-width-under-30-height-draw_events.snap
+++ b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-full-width-under-30-height-draw_events.snap
@@ -4,7 +4,7 @@ expression: terminal_draw_events.lock().unwrap().join(SNAPSHOT_SECTION_SEPARATOR
---
IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
┌Utilization by process name──────────────────────────────────────────────────────────────────┐┌Utilization by remote address────────────────────────────────────────────────────────────────┐
-│Process Connections Rate (Up / Down) ││Remote Address Connections Rate (Up / Down) │
+│Process PID Connections Rate (Up / Down) ││Remote Address Connections Rate (Up / Down) │
│ ││ │
│ ││ │
│ ││ │
@@ -36,30 +36,7 @@ IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
98. 0B
- 5 1 0.00B / 28.00B 3.3.3.3 1 0.00B / 28.00B
- 4 1 0.00B / 26.00B 2.2.2.2 1 0.00B / 26.00B
- 1 1 0.00B / 22.00B 1.1.1.1 1 0.00B / 22.00B
- 2 1 0.00B / 21.00B 4.4.4.4 1 0.00B / 21.00B
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ 5 5 1 0.00B / 28.00B 3.3.3.3 1 0.00B / 28.00B
+ 4 4 1 0.00B / 26.00B 2.2.2.2 1 0.00B / 26.00B
+ 1 1 1 0.00B / 22.00B 1.1.1.1 1 0.00B / 22.00B
+ 2 2 1 0.00B / 21.00B 4.4.4.4 1 0.00B / 21.00B
diff --git a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-120-width-full-height-draw_events.snap b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-120-width-full-height-draw_events.snap
index 9a49d50..d902735 100644
--- a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-120-width-full-height-draw_events.snap
+++ b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-120-width-full-height-draw_events.snap
@@ -4,7 +4,7 @@ expression: terminal_draw_events.lock().unwrap().join(SNAPSHOT_SECTION_SEPARATOR
---
IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
┌Utilization by process name──────────────────────────────────────────────────────────────────────────────────────────┐
-│Process Connections Rate (Up / Down) │
+│Process PID Connections Rate (Up / Down) │
│ │
│ │
│ │
@@ -57,10 +57,10 @@ IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
98. 0B
- 5 1 0.00B / 28.00B
- 4 1 0.00B / 26.00B
- 1 1 0.00B / 22.00B
- 2 1 0.00B / 21.00B
+ 5 5 1 0.00B / 28.00B
+ 4 4 1 0.00B / 26.00B
+ 1 1 1 0.00B / 22.00B
+ 2 2 1 0.00B / 21.00B
@@ -84,24 +84,4 @@ IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
3.3.3.3 1 0.00B / 28.00B
2.2.2.2 1 0.00B / 26.00B
1.1.1.1 1 0.00B / 22.00B
- 4.4.4.4 1 0.00B / 21.00B
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+ 4.4.4.4 1 0.00B / 21.00B
diff --git a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-120-width-under-30-height-draw_events.snap b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-120-width-under-30-height-draw_events.snap
index bbd6326..f978b86 100644
--- a/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-120-width-under-30-height-draw_events.snap
+++ b/src/tests/cases/snapshots/bandwhich__tests__cases__ui__layout-under-120-width-under-30-height-draw_events.snap
@@ -4,7 +4,7 @@ expression: terminal_draw_events.lock().unwrap().join(SNAPSHOT_SECTION_SEPARATOR
---
IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
┌Utilization by process name──────────────────────────────────────────────────────────────────────────────────────────┐
-│Process Connections Rate (Up / Down) │
+│Process PID Connections Rate (Up / Down) │
│ │
│ │
│ │
@@ -36,30 +36,7 @@ IF: interface_name | Total Rate (Up / Down): 0.00B / 0.00B
98. 0B
- 5 1 0.00B / 28.00B
- 4 1 0.00B / 26.00B
- 1 1 0.00B / 22.00B
- 2 1 0.00B / 21.00B
-
-
-
-