eclipse 中用GoogleTest 测试C++程序
2010-10-20 23:13
465 查看
近来学习C++程序,所用的工具是eclipse,用GoogleTest进行测试,老是出现一下的错误,不知道是怎么回事,请高手指教,感谢。。。。
**** Internal Builder is used for build ****
g++ -ID:/gtest/include -O0 -g3 -Wall -c -fmessage-length=0 -osrc/test.o ../src/test.cpp
../src/test.cpp:13:22: error: '_TCHAR' has not been declared
../src/test.cpp: In function 'int _tmain(int, int**)':
../src/test.cpp:15:40: error: no matching function for call to 'InitGoogleTest(int*, int**&)'
D:/gtest/include/gtest/gtest.h:1122:6: note: candidates are: void testing::InitGoogleTest(int*, char**)
D:/gtest/include/gtest/gtest.h:1126:6: note: void testing::InitGoogleTest(int*, wchar_t**)
Build error occurred, build is stopped
Time consumed: 2016 ms.
**** Internal Builder is used for build ****
g++ -ID:/gtest/include -O0 -g3 -Wall -c -fmessage-length=0 -osrc/test.o ../src/test.cpp
../src/test.cpp:13:22: error: '_TCHAR' has not been declared
../src/test.cpp: In function 'int _tmain(int, int**)':
../src/test.cpp:15:40: error: no matching function for call to 'InitGoogleTest(int*, int**&)'
D:/gtest/include/gtest/gtest.h:1122:6: note: candidates are: void testing::InitGoogleTest(int*, char**)
D:/gtest/include/gtest/gtest.h:1126:6: note: void testing::InitGoogleTest(int*, wchar_t**)
Build error occurred, build is stopped
Time consumed: 2016 ms.
相关文章推荐
- C++测试利器--google test开源测试框架
- GoogleTest测试C++代码
- eclipse测试C++程序01-scanf结构体输入浮点数、浮点数的表示
- 玩转Google开源C++单元测试框架Google Test系列(gtest)之五 - 死亡测试
- 使用Google Unit Test 测试你的C++代码
- Ubuntu安装GoogleTest框架并测试C++代码
- 玩转Google开源C++单元测试框架Google Test系列(gtest)之五 - 死亡测试
- C++测试利器--google test开源测试框架
- C程序:使用 googletest 测试框架
- Google C++ Test Framework (一)通过ASSERT和EXPECT宏完成的测试
- 玩转Google开源C++单元测试框架Google Test系列(gtest)之五 - 死亡测试
- 为什么使用googletest,而不是其他C++测试框架(译自google faq的该问题)
- 玩转Google开源C++单元测试框架Google Test系列(gtest)之五 - 死亡测试
- GoogleTest框架测试C++代码
- 玩转Google开源C++单元测试框架Google Test系列(gtest)之五 - 死亡测试
- Google C++ Test Framework (二)为用例中的测试进行统一的配置
- Google C++单元测试框架(Gtest)系列教程之三——测试固件(Test fixture)
- Google C++单元测试框架(Gtest)系列教程之三——测试固件(Test fixture)
- Google C++单元测试框架(Gtest)系列教程之三——测试固件(Test fixture)
- 玩转Google开源C++单元测试框架Google Test系列(gtest)之五 - 死亡测试