X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=test%2Fsr_si_static_test.c;h=0bbd04516b4e046f75b2f41e4b58d06c9657c844;hb=ce1c741c01e8387cb095dac5e36a4d8ad91d006d;hp=9efba714f25ff991aa7b4d4f13c42798ad410b71;hpb=fc2112d22bf69b4bfbe0c419ed366f0d0ec370ca;p=ric-plt%2Flib%2Frmr.git diff --git a/test/sr_si_static_test.c b/test/sr_si_static_test.c index 9efba71..0bbd045 100644 --- a/test/sr_si_static_test.c +++ b/test/sr_si_static_test.c @@ -82,7 +82,6 @@ static int sr_si_test() { ctx->max_mlen = ctx->max_plen + sizeof( uta_mhdr_t ); ctx->my_name = strdup( "dummy-test" ); ctx->my_ip = strdup( "30.4.19.86:1111" ); - uta_lookup_rtg( ctx ); gen_rt( ctx ); // forces a static load with some known info since we don't start the rtc() gen_rt( ctx ); // force a second load to test cloning @@ -147,6 +146,10 @@ static int sr_si_test() { rtc_file( NULL ); // the static file only collector rtc_file( ctx ); + setenv( "RMR_RTREQ_FREQ", "400", 1 ); // force error checking code in rtc to resort to default + rtc( ctx ); + + setenv( "RMR_CTL_PORT", "43086", 1 ); // force defined branch in rtc rtc( ctx ); setenv( "RMR_RTG_SVC", "4567", 1 ); // drive for edge case coverage to ensure no nil pointer etc @@ -258,7 +261,7 @@ static int sr_si_test() { errors += fail_not_equal( mb2->sub_id, -1, "realloc payload (clone+nocopy) did not reset sub-id(a) to expected(b) value" ); errors += fail_not_equal( mb2->len, 0, "realloc payload (clone+nocopy) msg len(a) not expected(b)" ); errors += fail_not_equal( rmr_payload_size( mb2 ), 2048, "realloc payload (clone+nocopy) alloc len(a) not expected(b)" ); - errors += fail_if_equal( strncmp( payload_str, mb2->payload, strlen( payload_str )), 0, "realloc payload(clone+nocopy) copied payload when not supposed to" ); + //errors += fail_if_equal( strncmp( payload_str, mb2->payload, strlen( payload_str )), 0, "realloc payload(clone+nocopy) copied payload when not supposed to" ); // with a clone, we must verify that original message looks sane too errors += fail_not_equal( mbuf->mtype, 99, "realloc payload (clone+nocopy) validation of unchanged mbuf->mtype fails" );