|
11 | 11 |
|
12 | 12 | public class RecruitBoardFixture { |
13 | 13 |
|
| 14 | + public static final String REGION = "경기"; |
| 15 | + public static final int RECRUITMENT_COUNT = 1; |
| 16 | + public static final LocalDateTime START_DATE_TIME = createStartDateTime(); |
| 17 | + public static final LocalDateTime END_DATE_TIME = START_DATE_TIME.plusHours(1); |
| 18 | + public static final boolean ADMITTED = true; |
| 19 | + public static final long LOCATION_ID = 1L; |
| 20 | + public static final String TITLE = "봉사모집제목"; |
| 21 | + public static final String CONTENT = "봉사모집내용"; |
| 22 | + public static final String IMG_URL = "https://image.domain.com/links"; |
| 23 | + public static final VolunteerType VOLUNTEER_TYPE = OTHER; |
| 24 | + |
14 | 25 | private RecruitBoardFixture() { |
15 | 26 | } |
16 | 27 |
|
17 | 28 | public static RecruitBoard createRecruitBoard() { |
18 | | - LocalDateTime startDateTime = createStartDateTime(); |
19 | | - LocalDateTime endDateTime = startDateTime.plusHours(1); |
20 | 29 |
|
21 | 30 | RecruitmentInfo recruitmentInfo = RecruitmentInfo.builder() |
22 | | - .region("경기") |
23 | | - .recruitmentCount(1) |
24 | | - .volunteerStartDateTime(startDateTime) |
25 | | - .volunteerEndDateTime(endDateTime) |
26 | | - .volunteerType(OTHER) |
27 | | - .admitted(true) |
| 31 | + .region(REGION) |
| 32 | + .recruitmentCount(RECRUITMENT_COUNT) |
| 33 | + .volunteerStartDateTime(START_DATE_TIME) |
| 34 | + .volunteerEndDateTime(END_DATE_TIME) |
| 35 | + .volunteerType(VOLUNTEER_TYPE) |
| 36 | + .admitted(ADMITTED) |
28 | 37 | .build(); |
29 | 38 |
|
30 | 39 | return RecruitBoard.builder() |
31 | 40 | .centerId(UUID.randomUUID()) |
32 | | - .locationId(1L) |
33 | | - .title("봉사모집제목") |
34 | | - .content("봉사모집내용") |
35 | | - .imgUrl("https://image.domain.com/links") |
| 41 | + .locationId(LOCATION_ID) |
| 42 | + .title(TITLE) |
| 43 | + .content(CONTENT) |
| 44 | + .imgUrl(IMG_URL) |
36 | 45 | .recruitmentInfo(recruitmentInfo) |
37 | 46 | .build(); |
38 | 47 | } |
39 | 48 |
|
40 | 49 | public static RecruitBoard createRecruitBoard(String title) { |
41 | | - LocalDateTime startDateTime = createStartDateTime(); |
42 | | - LocalDateTime endDateTime = startDateTime.plusHours(1); |
43 | 50 |
|
44 | 51 | RecruitmentInfo recruitmentInfo = RecruitmentInfo.builder() |
45 | | - .region("경기") |
46 | | - .recruitmentCount(1) |
47 | | - .volunteerStartDateTime(startDateTime) |
48 | | - .volunteerEndDateTime(endDateTime) |
49 | | - .volunteerType(OTHER) |
50 | | - .admitted(true) |
| 52 | + .region(REGION) |
| 53 | + .recruitmentCount(RECRUITMENT_COUNT) |
| 54 | + .volunteerStartDateTime(START_DATE_TIME) |
| 55 | + .volunteerEndDateTime(END_DATE_TIME) |
| 56 | + .volunteerType(VOLUNTEER_TYPE) |
| 57 | + .admitted(ADMITTED) |
51 | 58 | .build(); |
52 | 59 |
|
53 | 60 | return RecruitBoard.builder() |
54 | 61 | .centerId(UUID.randomUUID()) |
55 | | - .locationId(1L) |
56 | | - .title(title) |
57 | | - .content("봉사모집내용") |
58 | | - .imgUrl("https://image.domain.com/links") |
| 62 | + .locationId(LOCATION_ID) |
| 63 | + .title(TITLE) |
| 64 | + .content(CONTENT) |
| 65 | + .imgUrl(IMG_URL) |
59 | 66 | .recruitmentInfo(recruitmentInfo) |
60 | 67 | .build(); |
61 | 68 | } |
62 | 69 |
|
63 | 70 | public static RecruitBoard createRecruitBoard(String title, UUID centerId, Long locationId) { |
64 | | - LocalDateTime startDateTime = createStartDateTime(); |
65 | | - LocalDateTime endDateTime = startDateTime.plusHours(1); |
66 | 71 |
|
67 | 72 | RecruitmentInfo recruitmentInfo = RecruitmentInfo.builder() |
68 | | - .region("경기") |
69 | | - .recruitmentCount(1) |
70 | | - .volunteerStartDateTime(startDateTime) |
71 | | - .volunteerEndDateTime(endDateTime) |
72 | | - .volunteerType(OTHER) |
73 | | - .admitted(true) |
| 73 | + .region(REGION) |
| 74 | + .recruitmentCount(RECRUITMENT_COUNT) |
| 75 | + .volunteerStartDateTime(START_DATE_TIME) |
| 76 | + .volunteerEndDateTime(END_DATE_TIME) |
| 77 | + .volunteerType(VOLUNTEER_TYPE) |
| 78 | + .admitted(ADMITTED) |
74 | 79 | .build(); |
75 | 80 |
|
76 | 81 | return RecruitBoard.builder() |
77 | 82 | .centerId(centerId) |
78 | 83 | .locationId(locationId) |
79 | 84 | .title(title) |
80 | | - .content("봉사모집내용") |
81 | | - .imgUrl("https://image.domain.com/links") |
| 85 | + .content(CONTENT) |
| 86 | + .imgUrl(IMG_URL) |
82 | 87 | .recruitmentInfo(recruitmentInfo) |
83 | 88 | .build(); |
84 | 89 | } |
85 | 90 |
|
86 | 91 | public static RecruitBoard createRecruitBoard(String title, UUID centerId) { |
87 | | - LocalDateTime startDateTime = createStartDateTime(); |
88 | | - LocalDateTime endDateTime = startDateTime.plusHours(1); |
89 | 92 |
|
90 | 93 | RecruitmentInfo recruitmentInfo = RecruitmentInfo.builder() |
91 | | - .region("경기") |
92 | | - .recruitmentCount(1) |
93 | | - .volunteerStartDateTime(startDateTime) |
94 | | - .volunteerEndDateTime(endDateTime) |
95 | | - .volunteerType(OTHER) |
96 | | - .admitted(true) |
| 94 | + .region(REGION) |
| 95 | + .recruitmentCount(RECRUITMENT_COUNT) |
| 96 | + .volunteerStartDateTime(START_DATE_TIME) |
| 97 | + .volunteerEndDateTime(END_DATE_TIME) |
| 98 | + .volunteerType(VOLUNTEER_TYPE) |
| 99 | + .admitted(ADMITTED) |
97 | 100 | .build(); |
98 | 101 |
|
99 | 102 | return RecruitBoard.builder() |
100 | 103 | .centerId(centerId) |
101 | | - .locationId(1L) |
| 104 | + .locationId(LOCATION_ID) |
102 | 105 | .title(title) |
103 | | - .content("봉사모집내용") |
104 | | - .imgUrl("https://image.domain.com/links") |
| 106 | + .content(CONTENT) |
| 107 | + .imgUrl(IMG_URL) |
105 | 108 | .recruitmentInfo(recruitmentInfo) |
106 | 109 | .build(); |
107 | 110 | } |
108 | 111 |
|
109 | 112 | public static RecruitBoard createRecruitBoard(VolunteerType type, UUID centerId) { |
110 | | - LocalDateTime startDateTime = createStartDateTime(); |
111 | | - LocalDateTime endDateTime = startDateTime.plusHours(1); |
112 | 113 |
|
113 | 114 | RecruitmentInfo recruitmentInfo = RecruitmentInfo.builder() |
114 | | - .region("경기") |
115 | | - .recruitmentCount(1) |
116 | | - .volunteerStartDateTime(startDateTime) |
117 | | - .volunteerEndDateTime(endDateTime) |
| 115 | + .region(REGION) |
| 116 | + .recruitmentCount(RECRUITMENT_COUNT) |
| 117 | + .volunteerStartDateTime(START_DATE_TIME) |
| 118 | + .volunteerEndDateTime(END_DATE_TIME) |
118 | 119 | .volunteerType(type) |
119 | | - .admitted(true) |
| 120 | + .admitted(ADMITTED) |
120 | 121 | .build(); |
121 | 122 |
|
122 | 123 | return RecruitBoard.builder() |
123 | 124 | .centerId(centerId) |
124 | | - .locationId(1L) |
125 | | - .title("봉사모집제목") |
126 | | - .content("봉사모집내용") |
127 | | - .imgUrl("https://image.domain.com/links") |
| 125 | + .locationId(LOCATION_ID) |
| 126 | + .title(TITLE) |
| 127 | + .content(CONTENT) |
| 128 | + .imgUrl(IMG_URL) |
128 | 129 | .recruitmentInfo(recruitmentInfo) |
129 | 130 | .build(); |
130 | 131 | } |
131 | 132 |
|
132 | 133 | public static RecruitBoard createRecruitBoard(Boolean admitted, UUID centerId) { |
133 | | - LocalDateTime startDateTime = createStartDateTime(); |
134 | | - LocalDateTime endDateTime = startDateTime.plusHours(1); |
135 | 134 |
|
136 | 135 | RecruitmentInfo recruitmentInfo = RecruitmentInfo.builder() |
137 | | - .region("경기") |
138 | | - .recruitmentCount(1) |
139 | | - .volunteerStartDateTime(startDateTime) |
140 | | - .volunteerEndDateTime(endDateTime) |
141 | | - .volunteerType(OTHER) |
| 136 | + .region(REGION) |
| 137 | + .recruitmentCount(RECRUITMENT_COUNT) |
| 138 | + .volunteerStartDateTime(START_DATE_TIME) |
| 139 | + .volunteerEndDateTime(END_DATE_TIME) |
| 140 | + .volunteerType(VOLUNTEER_TYPE) |
142 | 141 | .admitted(admitted) |
143 | 142 | .build(); |
144 | 143 |
|
145 | 144 | return RecruitBoard.builder() |
146 | 145 | .centerId(centerId) |
147 | | - .locationId(1L) |
148 | | - .title("봉사모집제목") |
149 | | - .content("봉사모집내용") |
150 | | - .imgUrl("https://image.domain.com/links") |
| 146 | + .locationId(LOCATION_ID) |
| 147 | + .title(TITLE) |
| 148 | + .content(CONTENT) |
| 149 | + .imgUrl(IMG_URL) |
151 | 150 | .recruitmentInfo(recruitmentInfo) |
152 | 151 | .build(); |
153 | 152 | } |
154 | 153 |
|
155 | | - |
156 | 154 | public static RecruitBoard createRecruitBoard(Long locationId) { |
157 | | - LocalDateTime startDateTime = createStartDateTime(); |
158 | | - LocalDateTime endDateTime = startDateTime.plusHours(1); |
159 | 155 |
|
160 | 156 | RecruitmentInfo recruitmentInfo = RecruitmentInfo.builder() |
161 | | - .region("경기") |
162 | | - .recruitmentCount(1) |
163 | | - .volunteerStartDateTime(startDateTime) |
164 | | - .volunteerEndDateTime(endDateTime) |
165 | | - .volunteerType(OTHER) |
166 | | - .admitted(true) |
| 157 | + .region(REGION) |
| 158 | + .recruitmentCount(RECRUITMENT_COUNT) |
| 159 | + .volunteerStartDateTime(START_DATE_TIME) |
| 160 | + .volunteerEndDateTime(END_DATE_TIME) |
| 161 | + .volunteerType(VOLUNTEER_TYPE) |
| 162 | + .admitted(ADMITTED) |
167 | 163 | .build(); |
168 | 164 |
|
169 | 165 | return RecruitBoard.builder() |
170 | 166 | .centerId(UUID.randomUUID()) |
171 | 167 | .locationId(locationId) |
172 | | - .title("봉사모집제목") |
173 | | - .content("봉사모집내용") |
174 | | - .imgUrl("https://image.domain.com/links") |
| 168 | + .title(TITLE) |
| 169 | + .content(CONTENT) |
| 170 | + .imgUrl(IMG_URL) |
175 | 171 | .recruitmentInfo(recruitmentInfo) |
176 | 172 | .build(); |
177 | 173 | } |
178 | 174 |
|
179 | 175 | public static RecruitBoard createRecruitBoard(UUID centerId) { |
180 | | - LocalDateTime startDateTime = createStartDateTime(); |
181 | | - LocalDateTime endDateTime = startDateTime.plusHours(1); |
182 | 176 |
|
183 | 177 | RecruitmentInfo recruitmentInfo = RecruitmentInfo.builder() |
184 | | - .region("경기") |
185 | | - .recruitmentCount(1) |
186 | | - .volunteerStartDateTime(startDateTime) |
187 | | - .volunteerEndDateTime(endDateTime) |
188 | | - .volunteerType(OTHER) |
189 | | - .admitted(true) |
| 178 | + .region(REGION) |
| 179 | + .recruitmentCount(RECRUITMENT_COUNT) |
| 180 | + .volunteerStartDateTime(START_DATE_TIME) |
| 181 | + .volunteerEndDateTime(END_DATE_TIME) |
| 182 | + .volunteerType(VOLUNTEER_TYPE) |
| 183 | + .admitted(ADMITTED) |
190 | 184 | .build(); |
191 | 185 |
|
192 | 186 | return RecruitBoard.builder() |
193 | 187 | .centerId(centerId) |
194 | | - .locationId(1L) |
195 | | - .title("봉사모집제목") |
196 | | - .content("봉사모집내용") |
197 | | - .imgUrl("https://image.domain.com/links") |
| 188 | + .locationId(LOCATION_ID) |
| 189 | + .title(TITLE) |
| 190 | + .content(CONTENT) |
| 191 | + .imgUrl(IMG_URL) |
198 | 192 | .recruitmentInfo(recruitmentInfo) |
199 | 193 | .build(); |
200 | 194 | } |
201 | 195 |
|
202 | 196 | public static RecruitBoard createRecruitBoard(UUID centerId, Long locationId) { |
203 | | - LocalDateTime startDateTime = createStartDateTime(); |
204 | | - LocalDateTime endDateTime = startDateTime.plusHours(1); |
205 | 197 |
|
206 | 198 | RecruitmentInfo recruitmentInfo = RecruitmentInfo.builder() |
207 | | - .region("경기") |
208 | | - .recruitmentCount(1) |
209 | | - .volunteerStartDateTime(startDateTime) |
210 | | - .volunteerEndDateTime(endDateTime) |
211 | | - .volunteerType(OTHER) |
212 | | - .admitted(true) |
| 199 | + .region(REGION) |
| 200 | + .recruitmentCount(RECRUITMENT_COUNT) |
| 201 | + .volunteerStartDateTime(START_DATE_TIME) |
| 202 | + .volunteerEndDateTime(END_DATE_TIME) |
| 203 | + .volunteerType(VOLUNTEER_TYPE) |
| 204 | + .admitted(ADMITTED) |
213 | 205 | .build(); |
214 | 206 |
|
215 | 207 | return RecruitBoard.builder() |
216 | 208 | .centerId(centerId) |
217 | 209 | .locationId(locationId) |
218 | | - .title("봉사모집제목") |
219 | | - .content("봉사모집내용") |
220 | | - .imgUrl("https://image.domain.com/links") |
| 210 | + .title(TITLE) |
| 211 | + .content(CONTENT) |
| 212 | + .imgUrl(IMG_URL) |
221 | 213 | .recruitmentInfo(recruitmentInfo) |
222 | 214 | .build(); |
223 | 215 | } |
224 | 216 |
|
225 | 217 | public static RecruitBoard createRecruitBoard(String region, VolunteerType volunteerType) { |
226 | | - LocalDateTime startDateTime = createStartDateTime(); |
227 | | - LocalDateTime endDateTime = startDateTime.plusHours(1); |
228 | 218 |
|
229 | 219 | RecruitmentInfo recruitmentInfo = RecruitmentInfo.builder() |
230 | 220 | .region(region) |
231 | | - .recruitmentCount(1) |
232 | | - .volunteerStartDateTime(startDateTime) |
233 | | - .volunteerEndDateTime(endDateTime) |
| 221 | + .recruitmentCount(RECRUITMENT_COUNT) |
| 222 | + .volunteerStartDateTime(START_DATE_TIME) |
| 223 | + .volunteerEndDateTime(END_DATE_TIME) |
234 | 224 | .volunteerType(volunteerType) |
235 | | - .admitted(true) |
| 225 | + .admitted(ADMITTED) |
236 | 226 | .build(); |
237 | 227 |
|
238 | 228 | return RecruitBoard.builder() |
239 | 229 | .centerId(UUID.randomUUID()) |
240 | | - .locationId(1L) |
241 | | - .title("봉사모집제목") |
242 | | - .content("봉사모집내용") |
243 | | - .imgUrl("https://image.domain.com/links") |
| 230 | + .locationId(LOCATION_ID) |
| 231 | + .title(TITLE) |
| 232 | + .content(CONTENT) |
| 233 | + .imgUrl(IMG_URL) |
244 | 234 | .recruitmentInfo(recruitmentInfo) |
245 | 235 | .build(); |
246 | 236 | } |
247 | 237 |
|
248 | 238 | public static RecruitBoard createRecruitBoard(Long locationId, String title) { |
249 | | - LocalDateTime startDateTime = createStartDateTime(); |
250 | | - LocalDateTime endDateTime = startDateTime.plusHours(1); |
251 | 239 |
|
252 | 240 | RecruitmentInfo recruitmentInfo = RecruitmentInfo.builder() |
253 | | - .region("경기") |
254 | | - .recruitmentCount(1) |
255 | | - .volunteerStartDateTime(startDateTime) |
256 | | - .volunteerEndDateTime(endDateTime) |
257 | | - .volunteerType(OTHER) |
258 | | - .admitted(true) |
| 241 | + .region(REGION) |
| 242 | + .recruitmentCount(RECRUITMENT_COUNT) |
| 243 | + .volunteerStartDateTime(START_DATE_TIME) |
| 244 | + .volunteerEndDateTime(END_DATE_TIME) |
| 245 | + .volunteerType(VOLUNTEER_TYPE) |
| 246 | + .admitted(ADMITTED) |
259 | 247 | .build(); |
260 | 248 |
|
261 | 249 | return RecruitBoard.builder() |
262 | 250 | .centerId(UUID.randomUUID()) |
263 | 251 | .locationId(locationId) |
264 | 252 | .title(title) |
265 | | - .content("봉사모집내용") |
266 | | - .imgUrl("https://image.domain.com/links") |
| 253 | + .content(CONTENT) |
| 254 | + .imgUrl(IMG_URL) |
267 | 255 | .recruitmentInfo(recruitmentInfo) |
268 | 256 | .build(); |
269 | 257 | } |
|
0 commit comments