fix(test): Correct unit test bugs 05/205/1
authorE. Scott Daniels <daniels@research.att.com>
Wed, 29 May 2019 13:38:43 +0000 (13:38 +0000)
committerE. Scott Daniels <daniels@research.att.com>
Wed, 29 May 2019 13:38:43 +0000 (13:38 +0000)
Return in mbuf_api_test.c was missing causing occasional
report of failed test when all tests passed.

unit_test.ksh wasn't properly searching for build directory
on systems which support lib64 naming conventions.

Change-Id: Idc208ef796c8dabf70c039e38fafab2a34db4df9
Signed-off-by: E. Scott Daniels <daniels@research.att.com>
test/mbuf_api_test.c
test/unit_test.ksh

index fdc221a..796888f 100644 (file)
@@ -102,4 +102,6 @@ int main( ) {
        } else {
                fprintf( stderr, "<OK>   mbuf_api tests pass\n" );
        }
+
+       return errors;
 }
index 559f7d3..c94d4cd 100755 (executable)
@@ -305,17 +305,17 @@ function mk_xml {
 # -----------------------------------------------------------------------------------------------------------------
 
 # we assume that the project has been built in the ../[.]build directory
-if [[ -d ../build/lib ]]
+if [[ -d ../build ]]
 then
-       export LD_LIBRARY_PATH=../build/lib
+       export LD_LIBRARY_PATH=../build/lib:../build/lib64
 else
-       if [[ -d ../.build/lib ]]
+       if [[ -d ../.build ]]
        then
-               export LD_LIBRARY_PATH=../.build/lib
+               export LD_LIBRARY_PATH=../.build/lib:../.build/lib64
                export C_INCLUDE_PATH=../.build/include
 
        else
-               echo "[WARN] cannot find ../[.]build/lib; things might not work"
+               echo "[WARN] cannot find build directory (tried ../build and ../.build); things might not work"
                echo ""
        fi
 fi