Teuchos Package Browser (Single Doxygen Collection)  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Macros
TypeConversions_UnitTest.cpp File Reference
#include "Teuchos_as.hpp"
#include "Teuchos_UnitTestHarness.hpp"
#include <limits>
Include dependency graph for TypeConversions_UnitTest.cpp:

Go to the source code of this file.

Macros

#define TEST_NOTHROW_WITH_MESSAGE(code)
 
#define UNIT_TEST_GROUP_ANY_INTEGER(AnyIntegerType)
 
#define UNIT_TEST_GROUP_SIGNED_INTEGER(SignedIntegerType)   TEUCHOS_UNIT_TEST_TEMPLATE_1_INSTANT( asSafe, stringToIntegerNegative, SignedIntegerType )
 

Macro Definition Documentation

#define TEST_NOTHROW_WITH_MESSAGE (   code)
Value:
try { \
(out) << "Test that code {"#code";} does not throw : "; \
code; \
(out) << "passes\n"; \
} \
catch (std::exception& theException) { \
(success) = false; \
out << "failed\n"; \
out << "\nException message for unexpected exception:\n\n"; \
{ \
Teuchos::OSTab l_tab(out); \
out << theException.what() << "\n\n"; \
} \
}
basic_OSTab< char > OSTab

Definition at line 48 of file TypeConversions_UnitTest.cpp.

#define UNIT_TEST_GROUP_ANY_INTEGER (   AnyIntegerType)
Value:
TEUCHOS_UNIT_TEST_TEMPLATE_1_INSTANT( asSafe, stringToIntegerPositive, AnyIntegerType ) \
TEUCHOS_UNIT_TEST_TEMPLATE_1_INSTANT( asSafe, stringToIntegerShouldThrow, AnyIntegerType )
TypeTo asSafe(const TypeFrom &t)
Convert from one value type to another, with validity checks if appropriate.
#define TEUCHOS_UNIT_TEST_TEMPLATE_1_INSTANT(TEST_GROUP, TEST_NAME, TYPE)
Instantiate a templated unit test with one template parameter.

Definition at line 1027 of file TypeConversions_UnitTest.cpp.

#define UNIT_TEST_GROUP_SIGNED_INTEGER (   SignedIntegerType)    TEUCHOS_UNIT_TEST_TEMPLATE_1_INSTANT( asSafe, stringToIntegerNegative, SignedIntegerType )

Definition at line 1031 of file TypeConversions_UnitTest.cpp.