Ari Parkkila
85154ae76f
TESTS: Add socket.set_timeout in udpsocket_echotest
...
Some packet loss may be expected/allowed with UDP.
Set socket timeout to continue testing if no response is received within a timeout.
2019-11-18 16:25:21 +00:00
Chris Trowbridge
4215e7316d
Switch to using mbed-trace for greentea test debug output
2019-11-18 16:25:21 +00:00
Kimmo Vaisanen
0dae909622
Add sender address and port verification to UDPSOCKET_ECHOTEST
...
recvfrom method returns sender address and port and this commit
adds a test for it in UDPSOCKET_ECHOTEST.
2019-11-18 15:48:17 +00:00
Marcin Tomczyk
a7054d7b93
UDPSOCKET_ECHOTEST change to tolerate duplicate packets
2019-11-18 15:42:08 +00:00
Michal Paszta
9f947e34c0
Fix compilation warnings from GCC
2019-10-16 11:53:52 +01:00
Tymoteusz Bloch
c22350589d
UDPSOCKET_ECHOTEST_NONBLOCK performance improvement.
2019-06-10 11:20:12 +02:00
Martin Kojtal
dd77957d45
Merge pull request #10665 from tymoteuszblochmobica/json
...
Add hardcoded Echo server defaults for Greentea socket tests.
2019-06-09 18:05:03 +01:00
Kevin Bracey
2fbbd9d2ca
Introduce Semaphore::acquire methods
...
Deprecate wait() in favour of acquire(), try_acquire(),
try_acquire_for() and try_acquire_until().
Brings Semaphore more into line with CMSIS-RTOS 2 (which uses "acquire"),
itself (as it has "release"), and other classes having "try", "try for"
and "try until".
Also steps away from vague "wait" term - the primary operation here is
to acquire the semaphore, and this will of course sleep.
2019-05-28 17:02:06 +03:00
Tymoteusz Bloch
d42ed4e6a9
Added hardcoded Echo server defaults for Greentea socket tests.
2019-05-27 14:41:17 +02:00
Mirela Chirica
26facc7f9b
Cellular: WISE-1570 needs greater receiving timeout to pass UDPSOCKET_ECHOTEST_NONBLOCK test
...
Reason for needing greater timeout could be this test's performance.
UDPSOCKET_ECHOTEST_BURST_NONBLOCK is implementing the receiving
differently and is passing with 1 second timeout.
2019-05-08 10:43:08 +03:00
Michal Paszta
d1017ea274
UDPSOCKET_ECHOTEST fails if a packet of any given size was not sent at least once
2019-04-18 11:38:11 +03:00
Michal Paszta
631540a421
ECHOTEST internal loop simplification and fix
...
The loop was wrongly incrementing the index of the array after assiging
the value. Thus the first array element was used twice and the last one
was never user. The issue is fixed and the loops are refactored and
simplified to avoid such confusion in the future.
2019-04-15 11:54:03 +03:00
Michal Paszta
266d4c43a2
Handle oversized packets in tcp, tls and udp socket tests
2019-03-27 11:01:16 +02:00
Cruz Monrreal
d26fe0fe55
Merge pull request #10184 from mirelachirica/wise_1570_udp_echotest_nonblocking
...
Cellular: Increase receiving timeout for UDP echo non-blocking test
2019-03-27 00:34:47 -05:00
Mirela Chirica
ec3c6f37f9
Cellular: WISE-1570 needs greater receiving timeout to pass UDPSOCKET_ECHOTEST_NONBLOCK test
...
Reason for needing greater timeout could be this test's performance.
UDPSOCKET_ECHOTEST_BURST_NONBLOCK is implementing the receiving
differently and is passing with 1 second timeout.
2019-03-26 09:10:02 +02:00
Michal Paszta
b7ed4b5d9e
Refactor socket stats to reduce bioler plate
...
Add a proper test case setup and teardown which does the socket stats
checks in tcp, udp and tls.
2019-03-14 11:09:35 +02:00
kegilbert
194fa129fb
Update recently added previous macro name uses in tests
2019-03-01 13:53:47 -06:00
Ari Parkkila
56badd8616
Change TESTS/netsocket/ for cellular testing
2019-02-13 01:30:42 -08:00
Veijo Pesonen
df3cdaa983
tests-netsocket-udp: UDPSOCKET_ECHOTEST_NONBLOCK execution time limit
...
Test case is allowed to take not more than a half what has been given
to the whole UDP suite.
UDP test cases reorganized so that the longest running ones are
executed last.
2019-02-04 12:33:34 +02:00
Veijo Pesonen
4d31455a0f
tests-netsocket-udp: UDPSOCKET_ECHOTEST_NONBLOCK restores non-blocking
...
Fixes a bug where after dropping bad packets receiver doesn't restore
the socket back to non-blocking state as it's supposed to.
2019-01-31 12:59:40 +02:00
Cruz Monrreal
68deb05d1b
Merge pull request #9376 from michalpasztamobica/tcpsocket_greentea
...
TCP/UDP greentea tests refactoring and cleanup
2019-01-17 21:52:40 -06:00
Michal Paszta
6e629e1ba6
Gemalto Crinterion UDP test adjustments
...
Adjusting the tests to match the cellular modems ELS61-E2 and BGS2-W requirements.
2019-01-15 12:38:48 +01:00
Michal Paszta
59e8dedb67
TCP/UDP greentea tests refactoring and cleanup
2019-01-15 10:00:35 +01:00
deepikabhavnani
c272377a81
Make sure no memory overhead if statistics are disabled
2018-11-26 09:42:45 -06:00
deepikabhavnani
117eb0bc87
Add socketstats stub functions for unittest and addressed reviews
2018-11-26 09:42:50 -06:00
Deepika
f6c1a40b29
Add config options for socket statistics
...
1. MBED_CONF_NSAPI_SOCKET_STATS_ENABLE to enable the statistics
2. MBED_CONF_NSAPI_SOCKET_STATS_MAX_COUNT max sockets statistics cached
2018-11-26 09:42:45 -06:00
Deepika
e7ea2927fc
Update udp test cases to verify network socket statistics
...
Cases Updated are:
1. UDPSOCKET_ECHOTEST_NONBLOCK
2. UDPSOCKET_OPEN_CLOSE_REPEAT
3. UDPSOCKET_OPEN_LIMIT
2018-11-26 09:42:45 -06:00
Kevin Bracey
1ef213ec89
Clean up Thread deprecation warnings
...
Static Thread methods and signal methods have been deprecated. Remove
all references in the main code, and most of the tests. Some tests of
the deprecated APIs themselves remain.
2018-10-12 14:57:13 +03:00
Mika Leppänen
3c03feff08
Updated greentea UDP tests to use default interface
2018-08-21 10:55:49 +03:00
Martin Kojtal
e52bb68f93
tests: astyle fix
...
All tests should comply to our coding standard now
2018-08-03 10:23:38 +01:00
Jarno Lamsa
6bdefd3041
Tolerate packet loss up to 30% in udp echo tests
2018-06-14 10:16:26 +03:00
Veijo Pesonen
3e11a3e666
Fixes findings from Greentea netsocket UDP test cases
2018-05-25 09:39:36 +03:00
Veijo Pesonen
21ec972798
Switches Greentea netsocket test case naming convention
...
From lowercase to uppercase and drops 'test_'-prefix. Test case
descriptions do also match to TC names now.
Additionally all the TCs are not behing MBED_EXTENDED_TESTS
anymore.
2018-05-25 09:39:36 +03:00
Veijo Pesonen
1b041721a0
Fixes Greentea UDP test cases
...
udpsocket_echotest.cpp
udpsocket_echotest_burst.cpp
2018-05-25 09:39:36 +03:00
Veijo Pesonen
1fef1602a2
Adds UDP Greentea test cases
...
udpsocket_echotest
udpsocket_echotest_nonblock
2018-05-25 09:39:36 +03:00