Skip to content

Commit 3ee310e

Browse files
chore(deps): bump org.junit:junit-bom from 6.0.3 to 6.1.0 (#7431)
* chore(deps): bump org.junit:junit-bom from 6.0.3 to 6.1.0 Bumps [org.junit:junit-bom](https://github.com/junit-team/junit-framework) from 6.0.3 to 6.1.0. - [Release notes](https://github.com/junit-team/junit-framework/releases) - [Commits](junit-team/junit-framework@r6.0.3...r6.1.0) --- updated-dependencies: - dependency-name: org.junit:junit-bom dependency-version: 6.1.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> * style: resolve `DLS_DEAD_LOCAL_STORE` in `testIteratorEmptyBag` --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: vil02 <65706193+vil02@users.noreply.github.com>
1 parent 4b8099c commit 3ee310e

2 files changed

Lines changed: 3 additions & 5 deletions

File tree

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
<dependency>
2121
<groupId>org.junit</groupId>
2222
<artifactId>junit-bom</artifactId>
23-
<version>6.0.3</version>
23+
<version>6.1.0</version>
2424
<type>pom</type>
2525
<scope>import</scope>
2626
</dependency>

src/test/java/com/thealgorithms/datastructures/bag/BagTest.java

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -98,11 +98,9 @@ void testIterator() {
9898
@Test
9999
void testIteratorEmptyBag() {
100100
Bag<String> bag = new Bag<>();
101-
int count = 0;
102-
for (String ignored : bag) {
103-
org.junit.jupiter.api.Assertions.fail("Iterator should not return any items for an empty bag");
101+
for (String item : bag) {
102+
org.junit.jupiter.api.Assertions.fail("Iterator returned item for an empty bag:" + item);
104103
}
105-
assertEquals(0, count, "Iterator should not traverse any items in an empty bag");
106104
}
107105

108106
@Test

0 commit comments

Comments
 (0)