[BAEL-3348] Added test to prove algorithm behaviour on array suggested in article comment
This commit is contained in:
parent
20566a4bca
commit
bdfe144e00
|
@ -85,4 +85,13 @@ class SmallestMissingPositiveIntegerUnitTest {
|
||||||
|
|
||||||
assertThat(result).isEqualTo(input.length);
|
assertThat(result).isEqualTo(input.length);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
void givenArrayFromArticleComment_whenSearchInUnsortedArrayBooleanArray_thenZero() {
|
||||||
|
int[] input = new int[] {11, 13, 14, 15};
|
||||||
|
|
||||||
|
int result = SmallestMissingPositiveInteger.searchInUnsortedArrayBooleanArray(input);
|
||||||
|
|
||||||
|
assertThat(result).isEqualTo(0);
|
||||||
|
}
|
||||||
}
|
}
|
Loading…
Reference in New Issue