IVGCVSW-4118 Fix long unit test execution
* Reduced sleep_for timings
* Removed duplicate SendStreamMetaDataPacket.
* Modified SendCounterPacket::WaitForPacketSent to use wait_for
* Modified SendCounterPacket::Send WaitingForAck to use wait_for
* Added destructor to StreamRedirector.
* Added method SendCounterPacketTests::HasWrittenData
* Restructured many tests in ProfilingTests.
Signed-off-by: Keith Davis <keith.davis@arm.com>
Change-Id: I55c59cac6674ac40a1056a5302a997d5da9e9d91
Signed-off-by: Colm Donelan <Colm.Donelan@arm.com>
diff --git a/src/profiling/ConnectionAcknowledgedCommandHandler.cpp b/src/profiling/ConnectionAcknowledgedCommandHandler.cpp
index 630b555..a2a045d 100644
--- a/src/profiling/ConnectionAcknowledgedCommandHandler.cpp
+++ b/src/profiling/ConnectionAcknowledgedCommandHandler.cpp
@@ -37,9 +37,7 @@
// Once a Connection Acknowledged packet has been received, move to the Active state immediately
m_StateMachine.TransitionToState(ProfilingState::Active);
-
- // Send all the packet required for the handshake with the external profiling service
- m_SendCounterPacket.SendStreamMetaDataPacket();
+ // Send the counter directory packet.
m_SendCounterPacket.SendCounterDirectoryPacket(m_CounterDirectory);
m_SendTimelinePacket.SendTimelineMessageDirectoryPackage();