Teuchos_LocalTestingHelpers.hpp

Go to the documentation of this file.
00001 // @HEADER
00002 // ***********************************************************************
00003 // 
00004 //                    Teuchos: Common Tools Package
00005 //                 Copyright (2004) Sandia Corporation
00006 // 
00007 // Under terms of Contract DE-AC04-94AL85000, there is a non-exclusive
00008 // license for use of this work by or on behalf of the U.S. Government.
00009 // 
00010 // This library is free software; you can redistribute it and/or modify
00011 // it under the terms of the GNU Lesser General Public License as
00012 // published by the Free Software Foundation; either version 2.1 of the
00013 // License, or (at your option) any later version.
00014 //  
00015 // This library is distributed in the hope that it will be useful, but
00016 // WITHOUT ANY WARRANTY; without even the implied warranty of
00017 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00018 // Lesser General Public License for more details.
00019 //  
00020 // You should have received a copy of the GNU Lesser General Public
00021 // License along with this library; if not, write to the Free Software
00022 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
00023 // USA
00024 // Questions? Contact Michael A. Heroux (maherou@sandia.gov) 
00025 // 
00026 // ***********************************************************************
00027 // @HEADER
00028 
00029 #ifndef TEUCHOS_LOCAL_TESTING_HELPERS_HPP
00030 #define TEUCHOS_LOCAL_TESTING_HELPERS_HPP
00031 
00032 
00043 #include "Teuchos_TestingHelpers.hpp"
00044 
00045 
00047 #define TEST_EQUALITY_CONST( v1, v2 ) \
00048   TEUCHOS_TEST_EQUALITY_CONST( v1, v2, out, success )
00049 
00050 
00052 #define TEST_EQUALITY( v1, v2 ) \
00053   TEUCHOS_TEST_EQUALITY( v1, v2, out, success )
00054 
00055 
00057 #define TEST_INEQUALITY_CONST( v1, v2 ) \
00058   TEUCHOS_TEST_INEQUALITY_CONST( v1, v2, out, success )
00059 
00060 
00062 #define TEST_INEQUALITY( v1, v2 ) \
00063   TEUCHOS_TEST_INEQUALITY( v1, v2, out, success )
00064 
00065 
00067 #define TEST_FLOATING_EQUALITY( v1, v2, tol ) \
00068   TEUCHOS_TEST_FLOATING_EQUALITY( v1, v2, tol, out, success )
00069 
00070 
00072 #define TEST_ITER_EQUALITY( iter1, iter2 ) \
00073   TEUCHOS_TEST_ITER_EQUALITY( iter1, iter2, out, success )
00074 
00075 
00077 #define TEST_ARRAY_ELE_EQUALITY( a, i, val ) \
00078    TEUCHOS_TEST_ARRAY_ELE_EQUALITY( a, i, val, false, out, local_success )
00079 
00081 #define TEST_ARRAY_ELE_INEQUALITY( a, i, val ) \
00082    TEUCHOS_TEST_ARRAY_ELE_INEQUALITY( a, i, val, false, out, local_success )
00083 
00084 
00086 #define TEST_COMPARE( v1, comp, v2 ) \
00087   TEUCHOS_TEST_COMPARE( v1, comp, v2, out, success )
00088 
00089 
00091 #define TEST_COMPARE_ARRAYS( a1, a2 ) \
00092   { \
00093     const bool result = compareArrays(a1,#a1,a2,#a2,out); \
00094     if (!result) success = false; \
00095   }
00096 
00097 
00099 #define TEST_COMPARE_FLOATING_ARRAYS( a1, a2, tol ) \
00100   { \
00101     const bool result = compareFloatingArrays(a1,#a1,a2,#a2,tol,out); \
00102     if (!result) success = false; \
00103   }
00104 
00105 
00107 #define TEST_THROW( code, ExceptType  ) \
00108   TEUCHOS_TEST_THROW( code, ExceptType, out, success  )
00109 
00110 
00112 #define TEST_NOTHROW( code  ) \
00113   TEUCHOS_TEST_NOTHROW( code, out, success  )
00114 
00115 
00116 #endif  // TEUCHOS_LOCAL_TESTING_HELPERS_HPP

Generated on Wed May 12 21:40:32 2010 for Teuchos - Trilinos Tools Package by  doxygen 1.4.7