Skip to content

Commit ba72d1c

Browse files
committed
test: 기수 정렬 테스트 추가
1 parent a5bb630 commit ba72d1c

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
package sort;
2+
3+
import static org.assertj.core.api.Assertions.assertThat;
4+
5+
import org.junit.jupiter.api.DisplayName;
6+
import org.junit.jupiter.api.Test;
7+
8+
class RadixSortTest {
9+
10+
@Test
11+
@DisplayName("기수_정렬_테스트")
12+
void 기수_정렬_테스트() {
13+
int[] array = {13, 212, 14, 7141, 10987, 6, 15};
14+
int maxLength = 5;
15+
16+
RadixSort radixSort = new RadixSort();
17+
radixSort.sort(array, maxLength);
18+
assertThat(array).containsExactly(6, 13, 14, 15, 212, 7141, 10987);
19+
}
20+
}

0 commit comments

Comments
 (0)