third_party/skia_m84/third_party/externals/angle2/src/common/FastVector_unittest.cpp
// Tests growing the fast vector beyond the fixed storage.
Tests growing the fast vector beyond the fixed storage.
Tests growing the fast vector beyond the fixed storage .
TEST(FastVector, Growth)
{
    constexpr size_t kSize = 4;
    FastVector<size_t, kSize> vec;
    for (size_t i = 0; i < kSize * 2; ++i)
    {
        vec.push_back(i);
    }
    EXPECT_EQ(kSize * 2, vec.size());
    for (size_t i = kSize * 2; i > 0; --i)
    {
        ASSERT_EQ(vec.back(), i - 1);
        vec.pop_back();
    }
    EXPECT_EQ(0u, vec.size());
}
TEST ( FastVector , Growth ) { constexpr size_t kSize = 4 ; FastVector < size_t , kSize > vec ; for ( size_t i = 0 ; i < kSize * 2 ; ++ i ) { vec . push_back ( i ) ; } EXPECT_EQ ( kSize * 2 , vec . size ( ) ) ; for ( size_t i = kSize * 2 ; i > 0 ; -- i ) { ASSERT_EQ ( vec . back ( ) , i - 1 ) ; vec . pop_back ( ) ; } EXPECT_EQ ( 0u , vec . size ( ) ) ; }
Tests growing the fast vector beyond the fixed storage.
Tests growing the fast vector beyond the fixed storage .