Ejemplo n.º 1
0
IUTEST_TYPED_TEST(MultiTypedTest, Get)
{
    typedef typename TypeParam:: template get<0>::type  Type1;
    typedef typename TypeParam:: template get<1>::type  Type2;

#if IUTEST_HAS_STATIC_ASSERT_TYPEEQ
    ::iutest::StaticAssertTypeEq< Type1, int >();
#endif
    IUTEST_SUCCEED() << ::iutest::detail::GetTypeName< Type1 >();
    IUTEST_SUCCEED() << ::iutest::detail::GetTypeName< Type2 >();
}
Ejemplo n.º 2
0
IUTEST_TYPED_TEST(TypedPrintToTest, Print)
{
    TypeParam a = 0;
    TypeParam& b = a;
    const TypeParam c = a;
    const volatile TypeParam d = a;

    IUTEST_SUCCEED() << ::iutest::PrintToString(a);
    IUTEST_SUCCEED() << ::iutest::PrintToString(b);
    IUTEST_SUCCEED() << ::iutest::PrintToString(c);
    IUTEST_SUCCEED() << ::iutest::PrintToString(d);
}
Ejemplo n.º 3
0
IUTEST(PrintToTest, RawArray)
{
    {
        unsigned char a[3] = {0, 1, 2};
        const unsigned char b[3] = {0, 1, 2};
        const volatile unsigned char c[3] = {0, 1, 2};
        volatile unsigned char d[3] = {0, 1, 2};

        IUTEST_SUCCEED() << ::iutest::PrintToString(a);
        IUTEST_SUCCEED() << ::iutest::PrintToString(b);
        IUTEST_SUCCEED() << ::iutest::PrintToString(c);
        IUTEST_SUCCEED() << ::iutest::PrintToString(d);
    }
    {
        char a[3] = {0, 1, 2};
        const char b[3] = {0, 1, 2};
        const volatile char c[3] = {0, 1, 2};
        volatile char d[3] = {0, 1, 2};

        IUTEST_SUCCEED() << ::iutest::PrintToString(a);
        IUTEST_SUCCEED() << ::iutest::PrintToString(b);
        IUTEST_SUCCEED() << ::iutest::PrintToString(c);
        IUTEST_SUCCEED() << ::iutest::PrintToString(d);
    }
}
Ejemplo n.º 4
0
IUTEST(PrintToTest, Test1)
{
    ::std::vector<int> a;
    for( int i=0; i < 10; ++i )
        a.push_back(i);
    IUTEST_SUCCEED() << ::iutest::PrintToString(a);

    int* pi=NULL;
    void* p=NULL;
    IUTEST_SUCCEED() << ::iutest::PrintToString(p);
    IUTEST_SUCCEED() << ::iutest::PrintToString(pi);

    Bar bar = {0, 1, 2};
    IUTEST_SUCCEED() << ::iutest::PrintToString(bar);
}
Ejemplo n.º 5
0
IUTEST(PrintToTest, U32String)
{
    IUTEST_SUCCEED() << ::iutest::PrintToString(U"テスト");
}
Ejemplo n.º 6
0
IUTEST_P(ParamDirectTest, Test)
{
    IUTEST_SUCCEED() << GetParam();
}
Ejemplo n.º 7
0
IUTEST(Foo, Ok)
{
    IUTEST_SUCCEED() << "not show.";
}