assign.cc (test01): Add tests.
2001-12-16 Paolo Carlini <pcarlini@unitus.it> * testsuite/21_strings/assign.cc (test01): Add tests. From-SVN: r48078
This commit is contained in:
parent
3e037140fa
commit
4b428ee570
|
@ -1,3 +1,7 @@
|
|||
2001-12-16 Paolo Carlini <pcarlini@unitus.it>
|
||||
|
||||
* testsuite/21_strings/assign.cc (test01): Add tests.
|
||||
|
||||
2001-12-15 Paolo Carlini <pcarlini@unitus.it>
|
||||
Nathan Myers <ncm@cantrip.org>
|
||||
|
||||
|
|
|
@ -37,6 +37,13 @@ test01()
|
|||
if (i != string::npos)
|
||||
aux.assign(aux, i + 1, string::npos);
|
||||
VERIFY(aux == "Hawaii");
|
||||
|
||||
aux = strlit;
|
||||
i = aux.rfind("r/");
|
||||
if (i != string::npos)
|
||||
aux.assign(aux, i + 1, string::npos);
|
||||
VERIFY(aux.c_str()[9] == 'B');
|
||||
VERIFY(aux == "/Hanalei Bay/Kauai/Hawaii");
|
||||
}
|
||||
|
||||
// assign(const basic_string& __str, size_type __pos, size_type __n)
|
||||
|
|
Loading…
Reference in New Issue