- Timestamp:
- Mar 20, 2011, 3:37:07 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/egtra/ab5.0/abdev/ab-test/jenga.cpp
r818 r819 8 8 #include "stdafx.h" 9 9 10 #include < locale>10 #include <boost/assign.hpp> 11 11 #include <jenga/include/jenga.h> 12 12 13 using namespace boost::assign; 13 14 using namespace Jenga::Common; 14 15 … … 18 19 BOOST_AUTO_TEST_CASE( JengaCommonString ) 19 20 { 21 std::vector<std::string> v; 22 v += "ABC", "def", "123"; 23 24 BOOST_CHECK(IsExistString(v, "123")); 25 BOOST_CHECK(!IsExistString(v, "abc")); 26 20 27 std::string s = "Dete koi dete koi ike no koi"; 21 28 StringReplace(s, "koi", "ike"); 22 29 BOOST_CHECK_EQUAL(s, "Dete ike dete ike ike no ike"); 30 23 31 BOOST_CHECK_EQUAL(ToString(42), "42"); 24 32 BOOST_CHECK_EQUAL(ToString(-7), "-7"); 33 25 34 BOOST_CHECK_EQUAL(ToString(std::wstring(L"ABC123")), "ABC123"); 35 26 36 BOOST_CHECK(ToWString(std::string("ABC123")) == L"ABC123"); 37 27 38 BOOST_CHECK(IsIdentifierTopChar('a')); 28 39 BOOST_CHECK(IsIdentifierTopChar('z'));
Note:
See TracChangeset
for help on using the changeset viewer.