From 8523f92e4cec5f4145798280e5f98b39e546cea7 Mon Sep 17 00:00:00 2001 From: ahah525 Date: Tue, 8 Nov 2022 11:15:40 +0900 Subject: [PATCH] =?UTF-8?q?#35=20-=20Test:=20Ut.mapOf()=20=ED=85=8C?= =?UTF-8?q?=EC=8A=A4=ED=8A=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/example/mutbooks/util/UtTest.java | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 4Week_Mission/mutbooks/src/test/java/com/example/mutbooks/util/UtTest.java diff --git a/4Week_Mission/mutbooks/src/test/java/com/example/mutbooks/util/UtTest.java b/4Week_Mission/mutbooks/src/test/java/com/example/mutbooks/util/UtTest.java new file mode 100644 index 0000000..f35223f --- /dev/null +++ b/4Week_Mission/mutbooks/src/test/java/com/example/mutbooks/util/UtTest.java @@ -0,0 +1,21 @@ +package com.example.mutbooks.util; + +import org.junit.jupiter.api.DisplayName; +import org.junit.jupiter.api.Test; + +import java.util.Map; + +import static org.assertj.core.api.Assertions.assertThat; + +class UtTest { + @Test + @DisplayName("Ut.mapOf() 인자값을 map 으로 변환") + void t1() { + Map ages = Ut.mapOf("영수", 22, "철수", 33, "영희", 44, "민수", 55); + + assertThat(ages.get("영수")).isEqualTo(22); + assertThat(ages.get("철수")).isEqualTo(33); + assertThat(ages.get("영희")).isEqualTo(44); + assertThat(ages.get("민수")).isEqualTo(55); + } +} \ No newline at end of file