소스 검색

Merge pull request #42 from greboid/dev

Improve test coverage for Queued LinkedHashSet.
pull/43/head
Chris Smith 9 년 전
부모
커밋
d7a00ae6a0
1개의 변경된 파일6개의 추가작업 그리고 0개의 파일을 삭제
  1. 6
    0
      test/com/dmdirc/util/collections/QueuedLinkedHashSetTest.java

+ 6
- 0
test/com/dmdirc/util/collections/QueuedLinkedHashSetTest.java 파일 보기

@@ -53,6 +53,12 @@ public class QueuedLinkedHashSetTest {
53 53
         set.element();
54 54
     }
55 55
 
56
+    @Test
57
+    public void testElementWhenNotEmpty() {
58
+        set.offer("foo");
59
+        assertEquals("foo", set.element());
60
+    }
61
+
56 62
     @Test(expected = NoSuchElementException.class)
57 63
     public void testRemoveWhenNewlyCreated() {
58 64
         set.remove();

Loading…
취소
저장