-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: 이미지 URL 가진 엔티티에 모든 이미지 URL 반환하는 메서드 추가
- Loading branch information
1 parent
4c9a07f
commit 4477d58
Showing
9 changed files
with
104 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
backend/src/test/java/com/festago/artist/domain/ArtistTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
package com.festago.artist.domain; | ||
|
||
import static org.assertj.core.api.Assertions.assertThat; | ||
|
||
import com.festago.support.fixture.ArtistFixture; | ||
import java.util.List; | ||
import org.junit.jupiter.api.DisplayNameGeneration; | ||
import org.junit.jupiter.api.DisplayNameGenerator; | ||
import org.junit.jupiter.api.Nested; | ||
import org.junit.jupiter.api.Test; | ||
|
||
@DisplayNameGeneration(DisplayNameGenerator.ReplaceUnderscores.class) | ||
@SuppressWarnings("NonAsciiCharacters") | ||
class ArtistTest { | ||
|
||
@Nested | ||
class getImageUrls { | ||
|
||
@Test | ||
void 가지고_있는_모든_이미지_URL을_반환한다() { | ||
// given | ||
Artist artist = ArtistFixture.builder().build(); | ||
|
||
// when | ||
List<String> imageUrls = artist.getImageUrls(); | ||
|
||
// then | ||
assertThat(imageUrls) | ||
.containsExactlyInAnyOrder(artist.getProfileImage(), artist.getBackgroundImageUrl()); | ||
} | ||
} | ||
} |
32 changes: 32 additions & 0 deletions
32
backend/src/test/java/com/festago/festival/domain/FestivalTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
package com.festago.festival.domain; | ||
|
||
import static org.assertj.core.api.Assertions.assertThat; | ||
|
||
import com.festago.support.fixture.FestivalFixture; | ||
import java.util.List; | ||
import org.junit.jupiter.api.DisplayNameGeneration; | ||
import org.junit.jupiter.api.DisplayNameGenerator; | ||
import org.junit.jupiter.api.Nested; | ||
import org.junit.jupiter.api.Test; | ||
|
||
@DisplayNameGeneration(DisplayNameGenerator.ReplaceUnderscores.class) | ||
@SuppressWarnings("NonAsciiCharacters") | ||
class FestivalTest { | ||
|
||
@Nested | ||
class getImageUrls { | ||
|
||
@Test | ||
void 가지고_있는_모든_이미지_URL을_반환한다() { | ||
// given | ||
Festival festival = FestivalFixture.builder().build(); | ||
|
||
// when | ||
List<String> imageUrls = festival.getImageUrls(); | ||
|
||
// then | ||
assertThat(imageUrls) | ||
.containsExactlyInAnyOrder(festival.getPosterImageUrl()); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters