64 eNB connection is tested

This commit is contained in:
Sukchan Lee 2017-02-13 21:56:03 +09:00
parent 9c2f2ba026
commit f653e4ad78
3 changed files with 11 additions and 8 deletions

View File

@ -24,7 +24,7 @@ extern "C" {
#include <sys/socket.h>
#endif
#define MAX_NET_POOL_SIZE 100
#define MAX_NET_POOL_SIZE 256
/* Max length of interface name, ex: eth0, ath0 .. */
#define MAX_IFNAME_LEN 16

View File

@ -10,7 +10,7 @@
/* Server */
#include "event.h"
#define EVT_Q_DEPTH 16
#define EVT_Q_DEPTH 32
msgq_id event_create(void)
{

View File

@ -52,26 +52,27 @@ int enb_net_read(net_sock_t *sock, pkbuf_t *recvbuf, int size)
return rc;
}
#define NUM_OF_TEST_ENB 4
#define NUM_OF_TEST_DUPLICATED_ENB 4
#define TEST_S1_SETUP_RESPONSE_SIZE 27
#define TEST_S1_SETUP_FAILURE_SIZE 12
static void enb_setup_test1(abts_case *tc, void *data)
{
status_t rv;
net_sock_t *sock[NUM_OF_TEST_ENB];
net_sock_t *sock[NUM_OF_TEST_DUPLICATED_ENB];
pkbuf_t *sendbuf;
pkbuf_t *recvbuf = pkbuf_alloc(0, S1AP_SDU_SIZE);
s1ap_message message;
int rc;
int i;
for (i = 0; i < NUM_OF_TEST_ENB; i++)
for (i = 0; i < NUM_OF_TEST_DUPLICATED_ENB; i++)
{
sock[i] = enb_net_open();
ABTS_PTR_NOTNULL(tc, sock[i]);
}
for (i = 0; i < NUM_OF_TEST_ENB; i++)
for (i = 0; i < NUM_OF_TEST_DUPLICATED_ENB; i++)
{
int size = 0;
@ -95,7 +96,7 @@ static void enb_setup_test1(abts_case *tc, void *data)
s1ap_free_pdu(&message);
}
for (i = 0; i < NUM_OF_TEST_ENB; i++)
for (i = 0; i < NUM_OF_TEST_DUPLICATED_ENB; i++)
{
rv = enb_net_close(sock[i]);
ABTS_INT_EQUAL(tc, CORE_OK, rv);
@ -106,6 +107,8 @@ static void enb_setup_test1(abts_case *tc, void *data)
core_sleep(time_from_msec(3));
}
#define NUM_OF_TEST_ENB 64
static void enb_setup_test2(abts_case *tc, void *data)
{
status_t rv;
@ -149,7 +152,7 @@ static void enb_setup_test2(abts_case *tc, void *data)
pkbuf_free(recvbuf);
core_sleep(time_from_msec(3));
core_sleep(time_from_sec(1));
}
abts_suite *test_enb_setup(abts_suite *suite)