Skip to content

Commit

Permalink
fix: 실패하는 테스트 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
kiarakim committed Oct 15, 2023
1 parent 1471f3b commit 67ea3a4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
import com.carffeine.carffeine.station.service.review.ReplyService;
import com.carffeine.carffeine.station.service.review.ReviewQueryService;
import com.carffeine.carffeine.station.service.review.ReviewService;
import com.carffeine.carffeine.station.service.station.StationGridFacadeService;
import com.carffeine.carffeine.station.service.station.StationQueryService;
import com.carffeine.carffeine.station.service.station.StationService;
import org.springframework.boot.test.mock.mockito.MockBean;
Expand Down Expand Up @@ -78,4 +79,6 @@ public class MockBeanInjection {
protected StationQueryService stationQueryService;
@MockBean
protected AdminCityService adminCityService;
@MockBean
protected StationGridFacadeService stationGridFacadeService;
}
Original file line number Diff line number Diff line change
@@ -1,29 +1,17 @@
package com.carffeine.carffeine.station.domain.station;

import com.carffeine.carffeine.station.exception.StationException;
import org.junit.jupiter.api.DisplayNameGeneration;
import org.junit.jupiter.api.DisplayNameGenerator;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.ValueSource;

import java.math.BigDecimal;

import static org.assertj.core.api.Assertions.assertThat;
import static org.assertj.core.api.Assertions.assertThatThrownBy;

@DisplayNameGeneration(DisplayNameGenerator.ReplaceUnderscores.class)
@SuppressWarnings("NonAsciiCharacters")
class LatitudeTest {

@ValueSource(strings = {"32.9", "39.1"})
@ParameterizedTest
void 대한민국_범위의_위도가_아니면_예외가_발생한다(String expect) {
assertThatThrownBy(() -> Latitude.from(expect))
.isInstanceOf(StationException.class)
.hasMessage("유효하지 않는 위도입니다");
}

@Test
void 위도의_변화량에_따른_최소값을_구한다() {
//given
Expand Down

0 comments on commit 67ea3a4

Please sign in to comment.