Browse Source

tests: share stubs.h from msc_vlr_test as stubs.c

We also need stubs for the upcoming db_sms tests.

Due to a known bug of automake [1], we cannot use 'subdir-objects',
so as a side effect this change introduces some autoreconf warnings.

[1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=752993

Change-Id: I8846c940f2695fd33e1007fecac83e73f508bb34
changes/52/14352/2
Vadim Yanitskiy 3 years ago
parent
commit
98f0675ffc
  1. 14
      tests/msc_vlr/Makefile.am
  2. 1
      tests/msc_vlr/msc_vlr_test_authen_reuse.c
  3. 1
      tests/msc_vlr/msc_vlr_test_call.c
  4. 1
      tests/msc_vlr/msc_vlr_test_gsm_authen.c
  5. 1
      tests/msc_vlr/msc_vlr_test_gsm_ciph.c
  6. 1
      tests/msc_vlr/msc_vlr_test_hlr_reject.c
  7. 1
      tests/msc_vlr/msc_vlr_test_hlr_timeout.c
  8. 1
      tests/msc_vlr/msc_vlr_test_ms_timeout.c
  9. 1
      tests/msc_vlr/msc_vlr_test_no_authen.c
  10. 1
      tests/msc_vlr/msc_vlr_test_reject_concurrency.c
  11. 2
      tests/msc_vlr/msc_vlr_test_rest.c
  12. 1
      tests/msc_vlr/msc_vlr_test_ss.c
  13. 1
      tests/msc_vlr/msc_vlr_test_umts_authen.c
  14. 3
      tests/stubs.c

14
tests/msc_vlr/Makefile.am

@ -13,6 +13,7 @@ AM_CFLAGS = \
$(LIBOSMOABIS_CFLAGS) \
$(LIBOSMOSIGTRAN_CFLAGS) \
$(LIBOSMORANAP_CFLAGS) \
$(LIBOSMONETIF_CFLAGS) \
$(LIBASN1C_CFLAGS) \
$(LIBOSMOMGCPCLIENT_CFLAGS) \
$(LIBOSMOGSUPCLIENT_CFLAGS) \
@ -46,7 +47,6 @@ LDADD = \
noinst_HEADERS = \
msc_vlr_tests.h \
stubs.h \
$(NULL)
EXTRA_DIST = \
@ -94,61 +94,73 @@ noinst_PROGRAMS = \
msc_vlr_test_no_authen_SOURCES = \
msc_vlr_test_no_authen.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
msc_vlr_test_gsm_authen_SOURCES = \
msc_vlr_test_gsm_authen.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
msc_vlr_test_gsm_ciph_SOURCES = \
msc_vlr_test_gsm_ciph.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
msc_vlr_test_umts_authen_SOURCES = \
msc_vlr_test_umts_authen.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
msc_vlr_test_authen_reuse_SOURCES = \
msc_vlr_test_authen_reuse.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
msc_vlr_test_hlr_reject_SOURCES = \
msc_vlr_test_hlr_reject.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
msc_vlr_test_hlr_timeout_SOURCES = \
msc_vlr_test_hlr_timeout.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
msc_vlr_test_ms_timeout_SOURCES = \
msc_vlr_test_ms_timeout.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
msc_vlr_test_reject_concurrency_SOURCES = \
msc_vlr_test_reject_concurrency.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
msc_vlr_test_call_SOURCES = \
msc_vlr_test_call.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
msc_vlr_test_rest_SOURCES = \
msc_vlr_test_rest.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
msc_vlr_test_ss_SOURCES = \
msc_vlr_test_ss.c \
msc_vlr_tests.c \
$(srcdir)/../stubs.c \
$(NULL)
.PHONY: update_exp

1
tests/msc_vlr/msc_vlr_test_authen_reuse.c

@ -24,7 +24,6 @@
/* NOTE that further auth re-use tests exist in msc_vlr_test_hlr_reject.c */
#include "msc_vlr_tests.h"
#include "stubs.h"
static void _test_auth_reuse(enum osmo_rat_type via_ran,
int set_max_reuse_count,

1
tests/msc_vlr/msc_vlr_test_call.c

@ -22,7 +22,6 @@
*/
#include "msc_vlr_tests.h"
#include "stubs.h"
#include <osmocom/msc/gsm_04_08.h>

1
tests/msc_vlr/msc_vlr_test_gsm_authen.c

@ -22,7 +22,6 @@
*/
#include "msc_vlr_tests.h"
#include "stubs.h"
static void test_gsm_authen()
{

1
tests/msc_vlr/msc_vlr_test_gsm_ciph.c

@ -22,7 +22,6 @@
*/
#include "msc_vlr_tests.h"
#include "stubs.h"
static const struct osmo_gsm48_classmark classmark = {
// TODO

1
tests/msc_vlr/msc_vlr_test_hlr_reject.c

@ -22,7 +22,6 @@
*/
#include "msc_vlr_tests.h"
#include "stubs.h"
static void test_hlr_rej_auth_info_unknown_imsi()
{

1
tests/msc_vlr/msc_vlr_test_hlr_timeout.c

@ -22,7 +22,6 @@
*/
#include "msc_vlr_tests.h"
#include "stubs.h"
#include <osmocom/core/logging.h>

1
tests/msc_vlr/msc_vlr_test_ms_timeout.c

@ -22,7 +22,6 @@
*/
#include "msc_vlr_tests.h"
#include "stubs.h"
static void test_ms_timeout_lu_auth_resp()
{

1
tests/msc_vlr/msc_vlr_test_no_authen.c

@ -22,7 +22,6 @@
*/
#include "msc_vlr_tests.h"
#include "stubs.h"
static void test_no_authen()
{

1
tests/msc_vlr/msc_vlr_test_reject_concurrency.c

@ -22,7 +22,6 @@
*/
#include "msc_vlr_tests.h"
#include "stubs.h"
static void test_reject_2nd_conn()
{

2
tests/msc_vlr/msc_vlr_test_rest.c

@ -22,7 +22,7 @@
*/
#include "msc_vlr_tests.h"
#include "stubs.h"
#include <osmocom/msc/vlr.h>
#if 0

1
tests/msc_vlr/msc_vlr_test_ss.c

@ -21,7 +21,6 @@
*/
#include "msc_vlr_tests.h"
#include "stubs.h"
#define IMSI "901700000004620"

1
tests/msc_vlr/msc_vlr_test_umts_authen.c

@ -22,7 +22,6 @@
*/
#include "msc_vlr_tests.h"
#include "stubs.h"
static void _test_umts_authen(enum osmo_rat_type via_ran)
{

3
tests/msc_vlr/stubs.h → tests/stubs.c

@ -18,6 +18,9 @@
*
*/
#include <osmocom/core/linuxlist.h>
#include <osmocom/netif/stream.h>
void osmo_stream_srv_link_set_data(struct osmo_stream_srv_link *link, void *data) {}
struct osmo_fd *osmo_stream_srv_get_ofd(struct osmo_stream_srv *srv) { return NULL; }
void osmo_stream_srv_destroy(struct osmo_stream_srv *conn) {}
Loading…
Cancel
Save