Add more corner cases.
This commit is contained in:
1 parent
18f04da4ec
commit
6e947c6262
1 file changed
+3
-1
@@ -83,10 +83,12 @@ static void test_utf8_it(void)
|
|||||||
string_it_t it2;
|
string_it_t it2;
|
||||||
|
|
||||||
string_init(s);
|
string_init(s);
|
||||||
string_it_end(it2, s);
|
string_it(it2, s);
|
||||||
assert( string_it_get_pos(it2) == 0);
|
assert( string_it_get_pos(it2) == 0);
|
||||||
string_next(it2);
|
string_next(it2);
|
||||||
assert( string_it_get_pos(it2) == 0);
|
assert( string_it_get_pos(it2) == 0);
|
||||||
|
string_it_end(it2, s);
|
||||||
|
assert( string_it_get_pos(it2) == 0);
|
||||||
|
|
||||||
for(string_it(it, s) ; !string_end_p(it); string_next(it)) {
|
for(string_it(it, s) ; !string_end_p(it); string_next(it)) {
|
||||||
assert(0); // Shall not be called
|
assert(0); // Shall not be called
|
||||||
|
|||||||
Reference in new issue
Block a user