We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c278b2d commit e6393acCopy full SHA for e6393ac
1 file changed
src/test/java/com/thealgorithms/others/ArrayRotationTest.java
@@ -13,7 +13,7 @@ void shouldRotateArrayRightByTwoPositions() {
13
ArrayRotation.rotateRight(values, 2);
14
15
assertArrayEquals(new int[] {4, 5, 1, 2, 3}, values);
16
- }
+ }
17
18
@Test
19
void shouldRotateArrayLeftByTwoPositions() {
@@ -28,7 +28,7 @@ void shouldRotateArrayLeftByTwoPositions() {
28
void shouldHandleRotationGreaterThanArrayLength() {
29
int[] values = {10, 20, 30, 40};
30
31
- ArrayRotation.rotateRight(values, 2);
+ ArrayRotation.rotateRight(values, 6);
32
33
assertArrayEquals(new int[] {30, 40, 10, 20}, values);
34
}
@@ -49,7 +49,7 @@ void shouldHandleEmptyArrayWithoutErrors() {
49
ArrayRotation.rotateRight(values, 3);
50
51
assertArrayEquals(new int[] {}, values);
52
53
54
55
void shouldReturnOriginalArrayWhenRotationIsZero() {
@@ -59,5 +59,4 @@ void shouldReturnOriginalArrayWhenRotationIsZero() {
59
60
assertArrayEquals(new int[] {7, 8, 9}, values);
61
62
63
-
+}
0 commit comments