@@ -76,6 +76,8 @@ class EventConsumerSpec(implicit ev: ExecutionEnv)
7676 matchStatus = " 1st" ,
7777 eventId = " 7e730fbe-b013-3a0e-89cb-12b46260d7be" ,
7878 kickOffTimestamp = Some (1502477100L ),
79+ lineupsAvailable = Some (true ),
80+ detailedMatchStatus = Some (" FIRST_HALF" ),
7981 debug = false ,
8082 dryRun = None
8183 )
@@ -126,6 +128,8 @@ class EventConsumerSpec(implicit ev: ExecutionEnv)
126128 matchStatus = " HT" ,
127129 eventId = " bb346058-64d0-3ab1-9016-ea19d90837f0" ,
128130 kickOffTimestamp = Some (1502477100L ),
131+ lineupsAvailable = Some (true ),
132+ detailedMatchStatus = Some (" HALF_TIME" ),
129133 debug = false ,
130134 dryRun = None
131135 )
@@ -178,6 +182,8 @@ class EventConsumerSpec(implicit ev: ExecutionEnv)
178182 matchStatus = " 2nd" ,
179183 eventId = " a45dfca1-ead9-3d8c-bf83-c4966a737b05" ,
180184 kickOffTimestamp = Some (1502477100L ),
185+ lineupsAvailable = Some (true ),
186+ detailedMatchStatus = Some (" SECOND_HALF" ),
181187 debug = false ,
182188 dryRun = None
183189 )
@@ -229,6 +235,8 @@ class EventConsumerSpec(implicit ev: ExecutionEnv)
229235 matchStatus = " FT" ,
230236 eventId = " d59c9939-8199-3b8b-ad63-16aa020c1a73" ,
231237 kickOffTimestamp = Some (1502477100L ),
238+ lineupsAvailable = Some (true ),
239+ detailedMatchStatus = Some (" FULL_TIME" ),
232240 debug = false ,
233241 dryRun = None
234242 )
@@ -279,6 +287,8 @@ class EventConsumerSpec(implicit ev: ExecutionEnv)
279287 matchStatus = " 1st" ,
280288 eventId = " 1c8d67f9-0f32-342a-8543-aa3e21ee7da4" ,
281289 kickOffTimestamp = Some (1502477100L ),
290+ lineupsAvailable = Some (true ),
291+ detailedMatchStatus = Some (" FIRST_HALF" ),
282292 debug = false ,
283293 dryRun = None
284294 )
@@ -321,6 +331,8 @@ class EventConsumerSpec(implicit ev: ExecutionEnv)
321331 matchStatus = " 1st" ,
322332 eventId = " 7c92d6ca-9f20-398f-9510-eb4c179fb5ae" ,
323333 kickOffTimestamp = Some (1502477100L ),
334+ lineupsAvailable = Some (true ),
335+ detailedMatchStatus = Some (" FIRST_HALF" ),
324336 debug = false ,
325337 dryRun = None
326338 )
@@ -330,14 +342,14 @@ class EventConsumerSpec(implicit ev: ExecutionEnv)
330342 }
331343
332344 " A Notification EventConsumer" should {
333- " generate notification payloads for penalty kicks" in new MatchEventsContext {
345+ " not generate normal notifications for penalty shootout kicks" in new MatchEventsContext {
334346 override def matchDayLA : MatchDay =
335347 super .matchDayLA.copy(date = ZonedDateTime .now().plusHours(1 ))
336348
337349 val result : List [NotificationPayload ] =
338350 eventConsumer.eventsToNotifications(matchDataLA)
339351
340- result must contain((payload : NotificationPayload ) => payload.title.getOrElse(" " ) == " Penalty Kick" )
352+ result must not contain((payload : NotificationPayload ) => payload.title.getOrElse(" " ) == " Penalty Kick" )
341353 }
342354
343355 }
0 commit comments