Motivation
==========
This test is one of the longer running non-kernel
non-destructive tests, taking ~7 minutes to run
in my development environment.
Solution
========
By reducing the the sleeps from a half second to a tenth of a second,
the test passes from 364.0s to 309.1s.
Known drawbacks
===============
None
Signed-off-by: Kienan Stewart <kstewart@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Change-Id: Ibe6c37d474edf5ca118c82669e073089d888ff84
local evcount=0
while [ $evcount -ne 10 ]; do
evcount=$(cat $bt_output_path | wc -l)
local evcount=0
while [ $evcount -ne 10 ]; do
evcount=$(cat $bt_output_path | wc -l)
done
pass "Live viewer read $evcount events, expect 10"
done
pass "Live viewer read $evcount events, expect 10"
local evcount=0
while [ $evcount -ne 10 ]; do
evcount=$(wc -l < "$bt_output_path")
local evcount=0
while [ $evcount -ne 10 ]; do
evcount=$(wc -l < "$bt_output_path")
done
pass "Live viewer read $evcount events, expect 10"
done
pass "Live viewer read $evcount events, expect 10"
local evcount=0
while [ $evcount -ne 12 ]; do
evcount=$(wc -l < "$bt_output_path")
local evcount=0
while [ $evcount -ne 12 ]; do
evcount=$(wc -l < "$bt_output_path")
done
pass "Live viewer read $evcount events, expect 12"
done
pass "Live viewer read $evcount events, expect 12"
# Continue only when there is only the last event remaining.
while [ ! -f "${file_sync_before_last_touch}" ]; do
# Continue only when there is only the last event remaining.
while [ ! -f "${file_sync_before_last_touch}" ]; do
done
# Take a first snapshot and validate that the events are present.
done
# Take a first snapshot and validate that the events are present.
# Wait for the before exit sync point. This ensure that we went over the
# last tracepoint.
while [ ! -f "${file_sync_before_exit_touch}" ]; do
# Wait for the before exit sync point. This ensure that we went over the
# last tracepoint.
while [ ! -f "${file_sync_before_exit_touch}" ]; do
done
# Make sure the snapshot contains the last event.
done
# Make sure the snapshot contains the last event.
diag "Waiting for live trace at url: $url"
while [ $zero_client_match -eq 0 ]; do
zero_client_match=$($BABELTRACE_BIN -i lttng-live $url | grep "0 client(s) connected" | wc -l)
diag "Waiting for live trace at url: $url"
while [ $zero_client_match -eq 0 ]; do
zero_client_match=$($BABELTRACE_BIN -i lttng-live $url | grep "0 client(s) connected" | wc -l)
done
pass "Waiting for live trace at url: $url"
}
done
pass "Waiting for live trace at url: $url"
}
diag "Waiting for live viewers on url: $url"
while [ $one_client_match -eq 0 ]; do
one_client_match=$($BABELTRACE_BIN -i lttng-live $url | grep "1 client(s) connected" | wc -l)
diag "Waiting for live viewers on url: $url"
while [ $one_client_match -eq 0 ]; do
one_client_match=$($BABELTRACE_BIN -i lttng-live $url | grep "1 client(s) connected" | wc -l)
done
pass "Waiting for live viewers on url: $url"
}
done
pass "Waiting for live viewers on url: $url"
}