File tree Expand file tree Collapse file tree 1 file changed +24
-0
lines changed
src/test/java/eatda/client/map Expand file tree Collapse file tree 1 file changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -85,5 +85,29 @@ class SearchShops {
8585 () -> assertThat (result .longitude ()).isEqualTo (127.05300772497776 )
8686 );
8787 }
88+
89+ @ Test
90+ void 검색_결과가_없을_경우_빈_리스트를_반환한다 () {
91+ String url = "https://dapi.kakao.com/v2/local/search/keyword.json" ;
92+ String responseBody = """
93+ {
94+ "documents": [],
95+ "meta": {
96+ "is_end": true,
97+ "pageable_count": 0,
98+ "same_name": {
99+ "keyword": "존재하지 않는 가게",
100+ "region": [],
101+ "selected_region": ""
102+ },
103+ "total_count": 0
104+ }
105+ }""" ;
106+ setMockServer (HttpMethod .GET , url , responseBody );
107+
108+ List <StoreSearchResult > results = mapClient .searchShops ("존재하지 않는 가게" );
109+
110+ assertThat (results ).isEmpty ();
111+ }
88112 }
89113}
You can’t perform that action at this time.
0 commit comments