From: <bi...@us...> - 2013-12-02 18:09:05
|
Revision: 9603 http://sourceforge.net/p/oorexx/code-0/9603 Author: bigrixx Date: 2013-12-02 18:09:02 +0000 (Mon, 02 Dec 2013) Log Message: ----------- [#1184] CIrcularQueue resize() method removes too many items Modified Paths: -------------- test/trunk/ooRexx/base/class/CircularQueue.testGroup Modified: test/trunk/ooRexx/base/class/CircularQueue.testGroup =================================================================== --- test/trunk/ooRexx/base/class/CircularQueue.testGroup 2013-12-02 17:31:41 UTC (rev 9602) +++ test/trunk/ooRexx/base/class/CircularQueue.testGroup 2013-12-02 18:09:02 UTC (rev 9603) @@ -764,7 +764,23 @@ self~assertSame(2, c~items) self~assertTrue(sameContent(c, .circularqueue~of(2,3))) +::method test_bug_1184 + c = .circularqueue~of(1,2,3,4,5,6) + c~resize(3) + + self~assertSame(3, c~size) + self~assertSame(3, c~items) + self~assertTrue(sameContent(c, .circularqueue~of(4,5,6))) + + c = .circularqueue~of(1,2,3,4,5,6) + c~resize(3, "L") + + self~assertSame(3, c~size) + self~assertSame(3, c~items) + self~assertTrue(sameContent(c, .circularqueue~of(1,2,3))) + + /* Test whether both collections contain the same entries. returns .true, if the same, .false else */ |