sigscale / snmp-collector

SNMP Manager for 3GPP Alarm IRP
Apache License 2.0
10 stars 0 forks source link

snmp_collector_snmp_SUITE ct run is failing #2

Open bhuvanplus opened 2 months ago

bhuvanplus commented 2 months ago

I have built and installed as explained in README.maintainer. When I tried to run the testsuite snmp_collector_snmp_SUITE, I got the following result. Why is it failing? Please guide me.

~/git4/snmp_collector.build/test$ ct_run -suite snmp_collector_snmp_SUITE

1) The testcase init_per_suite is passed.

2) The test add_new_agent failed with an error "{undef,[{snmp_collector_snmp_SUITE,...},{...}|...]} ... Reason: undefined function snmp_collector_snmp_SUITE:add_new_agent/1"

3) All other testcases are SKIPPED with an error ERROR! init_per_testcase crashed! Location: [{snmp_collector_snmp_SUITE,init_snmp,690}, {snmp_collector_snmp_SUITE,init_per_testcase,65}, {test_server,do_init_per_testcase,1563}, {test_server,run_test_case_eval1,1264}, {test_server,run_test_case_eval,1234}] Reason: {{badmatch,{error,enoent}},

vances commented 2 months ago

In 2. we see that the function snmp_collector_snmp_SUITE:add_new_agent/1 is not found, which means it's not in the path. Is there a good reason why you are not running make check? I'm guessing you haven't compiled the test suites.

bhuvanplus commented 2 months ago

Thanks @vances. My mistake; I encountered error with "make check" as mentioned below. I ignored it wrongly thinking that it is something to do with dialyzer, which is useful to the code owner for static code analysis.

Apart from these Errors, "make check" reported "Unknown functions:" and "Unknown types:" as well. Please check the attached log.

makecheck.log

Please help me resolving the issue with "make check".

bhuvan@vm-alarm:~/git4/snmp_collector.build$ make check
....
done (warnings were emitted)
make[2]: *** [Makefile:483: .dialyzer_ok] Error 2
make[2]: Leaving directory '/home/bhuvan/git4/snmp_collector.build/test'
make[1]: *** [Makefile:365: check-am] Error 2
make[1]: Leaving directory '/home/bhuvan/git4/snmp_collector.build/test'
make: *** [Makefile:435: check-recursive] Error 1
bhuvan@vm-alarm:~/git4/snmp_collector.build$ 
vances commented 2 months ago

If the dialyzer step fails make check will not progress to common_test. Either fix the dialyser problems or arrange to run ct_run manually, with all the same parameterization and environment as in test/Makefile.