ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/test/tck/ConcurrentSkipListSetTest.java
(Generate patch)

Comparing jsr166/src/test/tck/ConcurrentSkipListSetTest.java (file contents):
Revision 1.47 by jsr166, Sat Mar 18 20:42:20 2017 UTC vs.
Revision 1.48 by jsr166, Fri Aug 4 04:59:23 2017 UTC

# Line 526 | Line 526 | public class ConcurrentSkipListSetTest e
526      }
527  
528      /**
529 <     * A deserialized serialized set has same elements
529 >     * A cloned set equals original
530 >     */
531 >    public void testClone() {
532 >        ConcurrentSkipListSet x = populatedSet(SIZE);
533 >        ConcurrentSkipListSet y = x.clone();
534 >
535 >        assertNotSame(x, y);
536 >        assertEquals(x.size(), y.size());
537 >        assertEquals(x, y);
538 >        assertEquals(y, x);
539 >        while (!x.isEmpty()) {
540 >            assertFalse(y.isEmpty());
541 >            assertEquals(x.pollFirst(), y.pollFirst());
542 >        }
543 >        assertTrue(y.isEmpty());
544 >    }
545 >
546 >    /**
547 >     * A deserialized/reserialized set equals original
548       */
549      public void testSerialization() throws Exception {
550          NavigableSet x = populatedSet(SIZE);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines