Skip to content

Commit

Permalink
Added another remove example (eugenp#2484)
Browse files Browse the repository at this point in the history
* moved test file to correct location

* added another remove example
  • Loading branch information
nbosecker authored and adamd1985 committed Aug 24, 2017
1 parent 154b59f commit 9b563d8
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,7 @@ public void whenAdd_thenRemoveFromBaseBag_thenContainsCorrect() {
Assert.assertFalse(baseBag.contains("lemon"));

Assert.assertTrue(baseBag.uniqueSet().contains("apple"));
Assert.assertFalse(baseBag.uniqueSet().contains("lemon"));
Assert.assertTrue(baseBag.uniqueSet().contains("lime"));


List<String> containList = new ArrayList<String>();
containList.add("apple");
containList.add("lemon");
Expand All @@ -56,11 +54,12 @@ public void whenAdd_thenRemoveFromBaseCollectionBag_thenContainsCorrect() {
baseCollectionBag.remove("lemon");
Assert.assertEquals(8, baseCollectionBag.size());
Assert.assertTrue(baseCollectionBag.contains("lemon"));

baseCollectionBag.remove("lemon",1);
Assert.assertEquals(7, baseCollectionBag.size());

Assert.assertTrue(baseBag.uniqueSet().contains("apple"));
Assert.assertTrue(baseBag.uniqueSet().contains("lemon"));
Assert.assertTrue(baseBag.uniqueSet().contains("lime"));


List<String> containList = new ArrayList<String>();
containList.add("apple");
containList.add("lemon");
Expand All @@ -81,5 +80,6 @@ public void whenAddtoTreeBag_thenRemove_thenContainsCorrect() {
treeBag.remove("apple");
Assert.assertEquals(9, treeBag.size());
Assert.assertEquals("banana", treeBag.first());

}
}

0 comments on commit 9b563d8

Please sign in to comment.