@@ -53,7 +53,9 @@ public function testItHasAFlowMeasure()
5353
5454 public function testItsAReissueIfItsNotifiedAndTheIdentifierHasChanged ()
5555 {
56- $ previousNotification = DivisionDiscordNotification::factory ()->create ();
56+ $ previousNotification = DivisionDiscordNotification::factory ()
57+ ->toDivisionWebhook ($ this ->webhook )
58+ ->create ();
5759 $ this ->flowMeasure ->divisionDiscordNotifications ()->sync (
5860 [
5961 $ previousNotification ->id => [
@@ -78,7 +80,9 @@ public function testItsAReissueIfItsNotifiedAndTheIdentifierHasChanged()
7880
7981 public function testItsAReissueIfItsActivatedAndTheIdentifierHasChanged ()
8082 {
81- $ previousNotification = DivisionDiscordNotification::factory ()->create ();
83+ $ previousNotification = DivisionDiscordNotification::factory ()
84+ ->toDivisionWebhook ($ this ->webhook )
85+ ->create ();
8286 $ this ->flowMeasure ->divisionDiscordNotifications ()->sync (
8387 [
8488 $ previousNotification ->id => [
@@ -103,7 +107,9 @@ public function testItsAReissueIfItsActivatedAndTheIdentifierHasChanged()
103107
104108 public function testItsAReissueIfItWasNotifiedAndTheIdentifierHasChangedForActivation ()
105109 {
106- $ previousNotification = DivisionDiscordNotification::factory ()->create ();
110+ $ previousNotification = DivisionDiscordNotification::factory ()
111+ ->toDivisionWebhook ($ this ->webhook )
112+ ->create ();
107113 $ this ->flowMeasure ->divisionDiscordNotifications ()->sync (
108114 [
109115 $ previousNotification ->id => [
@@ -206,7 +212,9 @@ public function testItsAReissueIfItsActivatedOnADifferentDivisionWebhook()
206212
207213 public function testItIsNotAReissueIfItsNotifiedAndTheIdentifierHasNotChanged ()
208214 {
209- $ previousNotification = DivisionDiscordNotification::factory ()->create ();
215+ $ previousNotification = DivisionDiscordNotification::factory ()
216+ ->toDivisionWebhook ($ this ->webhook )
217+ ->create ();
210218 $ this ->flowMeasure ->divisionDiscordNotifications ()->sync (
211219 [
212220 $ previousNotification ->id => [
@@ -231,7 +239,9 @@ public function testItIsNotAReissueIfItsNotifiedAndTheIdentifierHasNotChanged()
231239
232240 public function testItIsNotAReissueIfItsActivatedAndTheIdentifierHasNotChanged ()
233241 {
234- $ previousNotification = DivisionDiscordNotification::factory ()->create ();
242+ $ previousNotification = DivisionDiscordNotification::factory ()
243+ ->toDivisionWebhook ($ this ->webhook )
244+ ->create ();
235245 $ this ->flowMeasure ->divisionDiscordNotifications ()->sync (
236246 [
237247 $ previousNotification ->id => [
@@ -256,7 +266,9 @@ public function testItIsNotAReissueIfItsActivatedAndTheIdentifierHasNotChanged()
256266
257267 public function testItIsNotAReissueIfItsNotifiedAndThenActivatedTheIdentifierHasNotChanged ()
258268 {
259- $ previousNotification = DivisionDiscordNotification::factory ()->create ();
269+ $ previousNotification = DivisionDiscordNotification::factory ()
270+ ->toDivisionWebhook ($ this ->webhook )
271+ ->create ();
260272 $ this ->flowMeasure ->divisionDiscordNotifications ()->sync (
261273 [
262274 $ previousNotification ->id => [
@@ -307,7 +319,9 @@ public function testItIsNotAReissueIfItsNotifiedAndNeverBeenActivated()
307319
308320 public function testItIsNotAReissueIfItsWithdrawn ()
309321 {
310- $ previousNotification = DivisionDiscordNotification::factory ()->create ();
322+ $ previousNotification = DivisionDiscordNotification::factory ()
323+ ->toDivisionWebhook ($ this ->webhook )
324+ ->create ();
311325 $ this ->flowMeasure ->divisionDiscordNotifications ()->sync (
312326 [
313327 $ previousNotification ->id => [
@@ -332,7 +346,9 @@ public function testItIsNotAReissueIfItsWithdrawn()
332346
333347 public function testItIsNotAReissueIfItsExpired ()
334348 {
335- $ previousNotification = DivisionDiscordNotification::factory ()->create ();
349+ $ previousNotification = DivisionDiscordNotification::factory ()
350+ ->toDivisionWebhook ($ this ->webhook )
351+ ->create ();
336352 $ this ->flowMeasure ->divisionDiscordNotifications ()->sync (
337353 [
338354 $ previousNotification ->id => [
0 commit comments