Simplifies the definition of NativeArray. Works around a VC bug in StrictMock & NiceMock.

This commit is contained in:
zhanyong.wan
2009-09-16 17:38:08 +00:00
parent f5e1ce5b92
commit 4bd79e4f25
6 changed files with 117 additions and 81 deletions

View File

@@ -790,14 +790,14 @@ TEST(PrintStlContainerTest, NestedContainer) {
}
TEST(PrintStlContainerTest, OneDimensionalNativeArray) {
const int a[] = { 1, 2, 3 };
NativeArray<int> b(a, kReference);
const int a[3] = { 1, 2, 3 };
NativeArray<int> b(a, 3, kReference);
EXPECT_EQ("{ 1, 2, 3 }", Print(b));
}
TEST(PrintStlContainerTest, TwoDimensionalNativeArray) {
const int a[][3] = { { 1, 2, 3 }, { 4, 5, 6 } };
NativeArray<int[3]> b(a, kReference);
const int a[2][3] = { { 1, 2, 3 }, { 4, 5, 6 } };
NativeArray<int[3]> b(a, 2, kReference);
EXPECT_EQ("{ { 1, 2, 3 }, { 4, 5, 6 } }", Print(b));
}