X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;ds=sidebyside;f=tests%2Flibrary.at;h=ded0a2230b5f5cfc4cb3c35f9dc2c93bae09e642;hb=43d66d3bf3c61bbb23f093788ca3f565f0b2ebf6;hp=55adcfbf2d08a04e2af8004df9a5662fcf477d5d;hpb=4749f73d12c844b318af7f45cf45e1acac9f7c08;p=sliver-openvswitch.git diff --git a/tests/library.at b/tests/library.at index 55adcfbf2..ded0a2230 100644 --- a/tests/library.at +++ b/tests/library.at @@ -20,6 +20,15 @@ AT_CHECK([test-hmap], [0], [......... ]) AT_CLEANUP +AT_SETUP([test hash index]) +AT_CHECK([test-hindex], [0], [..................... +]) +AT_CLEANUP + +AT_SETUP([test atomic operations]) +AT_CHECK([test-atomic]) +AT_CLEANUP + AT_SETUP([test linked lists]) AT_CHECK([test-list], [0], [.. ]) @@ -103,6 +112,8 @@ AT_CLEANUP m4_foreach( [testname], [[ctz], + [round_up_pow2], + [round_down_pow2], [popcount], [log_2_floor], [bitwise_copy], @@ -114,7 +125,7 @@ m4_foreach( AT_CHECK([test-util testname], [0], [], []) AT_CLEANUP]) -AT_SETUP([test unix socket -- short pathname]) +AT_SETUP([test unix socket, short pathname - C]) AT_CHECK([test-unix-socket x]) AT_CLEANUP @@ -123,22 +134,33 @@ dnl go in a fixed-length field in struct sockaddr_un. Generally the limit dnl is about 100 bytes. On Linux, we work around this by indirecting through dnl a directory fd using /proc/self/fd/. We do not have a workaround dnl for other platforms, so we skip the test there. -AT_SETUP([test unix socket -- long pathname]) -AT_CHECK([dnl - case `uname` in dnl ( - *[[lL]]inux*) - exit 0 - ;; dnl ( - *) - dnl Magic exit code to tell Autotest to skip this test. - exit 77 - ;; - esac -]) +AT_SETUP([test unix socket, long pathname - C]) +AT_SKIP_IF([test ! -d /proc/self/fd]) +dnl Linux has a 108 byte limit; this is 150 bytes long. +longname=012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 +mkdir $longname +cd $longname +AT_CHECK([test-unix-socket ../$longname/socket socket]) +AT_CLEANUP + +AT_SETUP([test unix socket, short pathname - Python]) +AT_SKIP_IF([test $HAVE_PYTHON = no]) +AT_CHECK([$PYTHON $srcdir/test-unix-socket.py x]) +AT_CLEANUP + +dnl Unix sockets with long names are problematic because the name has to +dnl go in a fixed-length field in struct sockaddr_un. Generally the limit +dnl is about 100 bytes. On Linux, we work around this by indirecting through +dnl a directory fd using /proc/self/fd/. We do not have a workaround +dnl for other platforms, so we skip the test there. +AT_SETUP([test unix socket, long pathname - Python]) +AT_SKIP_IF([test $HAVE_PYTHON = no]) +AT_SKIP_IF([test ! -d /proc/self/fd]) dnl Linux has a 108 byte limit; this is 150 bytes long. -mkdir 012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 -cd 012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 -AT_CHECK([test-unix-socket ../012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789/socket socket]) +longname=012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789 +mkdir $longname +cd $longname +AT_CHECK([$PYTHON $abs_srcdir/test-unix-socket.py ../$longname/socket socket]) AT_CLEANUP AT_SETUP([ovs_assert])