new tests

[SVN r15688]
This commit is contained in:
Paul Mensonides
2002-10-03 21:55:27 +00:00
parent 608163ebbe
commit 7856c3b759
13 changed files with 479 additions and 0 deletions

26
test/array.cpp Normal file
View File

@ -0,0 +1,26 @@
# /* **************************************************************************
# * *
# * (C) Copyright Paul Mensonides 2002. Permission to copy, use, *
# * modify, sell, and distribute this software is granted provided *
# * this copyright notice appears in all copies. This software is *
# * provided "as is" without express or implied warranty, and with *
# * no claim at to its suitability for any purpose. *
# * *
# ************************************************************************** */
#
# /* See http://www.boost.org for most recent version. */
#
# include <boost/preprocessor/array.hpp>
# include <libs/preprocessor/regression/test.h>
# define ARRAY (3, (0, 1, 2))
// element access
BEGIN BOOST_PP_ARRAY_ELEM(1, ARRAY) == 1 END
BEGIN BOOST_PP_ARRAY_ELEM(2, (5, (0, 1, 2, 3, 4))) == 2 END
// size
BEGIN BOOST_PP_ARRAY_SIZE(ARRAY) == 3 END
BEGIN BOOST_PP_ARRAY_SIZE((5, (0, 1, 2, 3, 4))) == 5 END