From 2a200cff00ada9498db78ed613f0e59b0cf7e443 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Wed, 29 Apr 2009 17:32:38 +0200 Subject: [PATCH] stl: added todo test case about using same iterator with different containers --- test/teststl.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/test/teststl.cpp b/test/teststl.cpp index 82390256b..fd1815a79 100644 --- a/test/teststl.cpp +++ b/test/teststl.cpp @@ -37,6 +37,8 @@ private: { TEST_CASE(iterator1); TEST_CASE(iterator2); + TEST_CASE(iterator3); + TEST_CASE(STLSize); TEST_CASE(STLSizeNoErr); TEST_CASE(erase); @@ -95,6 +97,16 @@ private: ASSERT_EQUALS("[test.cpp:3]: (error) Same iterator is used with both foo and bar\n", errout.str()); } + void iterator3() + { + check("void foo()\n" + "{\n" + " i = l1.begin();\n" + " l2.insert(i, 0);\n" + "}\n"); + TODO_ASSERT_EQUALS("[test.cpp:4]: (error) Same iterator is used with both foo and bar\n", errout.str()); + } + void STLSize() {