22
33namespace NotificationChannels \Pushover \Test ;
44
5- use DMS \PHPUnitExtensions \ArraySubset \Assert ;
65use NotificationChannels \Pushover \PushoverReceiver ;
76use Orchestra \Testbench \TestCase ;
87
@@ -20,23 +19,30 @@ public function it_can_set_up_a_receiver_with_an_user_key()
2019 {
2120 $ pushoverReceiver = PushoverReceiver::withUserKey ('pushover-key ' );
2221
23- Assert::assertArraySubset (['user ' => 'pushover-key ' ], $ pushoverReceiver ->toArray ());
22+ $ this ->assertEquals ([
23+ 'user ' => 'pushover-key ' ,
24+ ], $ pushoverReceiver ->toArray ());
2425 }
2526
2627 /** @test */
2728 public function it_can_set_up_a_receiver_with_a_group_key ()
2829 {
2930 $ pushoverReceiver = PushoverReceiver::withGroupKey ('pushover-key ' );
3031
31- Assert::assertArraySubset (['user ' => 'pushover-key ' ], $ pushoverReceiver ->toArray ());
32+ $ this ->assertEquals ([
33+ 'user ' => 'pushover-key ' ,
34+ ], $ pushoverReceiver ->toArray ());
3235 }
3336
3437 /** @test */
3538 public function it_can_set_up_a_receiver_with_an_application_token ()
3639 {
3740 $ pushoverReceiver = PushoverReceiver::withUserKey ('pushover-key ' )->withApplicationToken ('pushover-token ' );
3841
39- Assert::assertArraySubset (['user ' => 'pushover-key ' , 'token ' => 'pushover-token ' ], $ pushoverReceiver ->toArray ());
42+ $ this ->assertEquals ([
43+ 'user ' => 'pushover-key ' ,
44+ 'token ' => 'pushover-token ' ,
45+ ], $ pushoverReceiver ->toArray ());
4046 }
4147
4248 /** @test */
@@ -54,24 +60,34 @@ public function it_can_add_a_single_device_to_the_receiver()
5460 {
5561 $ this ->pushoverReceiver ->toDevice ('iphone ' );
5662
57- Assert::assertArraySubset (['device ' => 'iphone ' ], $ this ->pushoverReceiver ->toArray ());
63+ $ this ->assertEquals ([
64+ 'user ' => 'pushover-key ' ,
65+ 'device ' => 'iphone ' ,
66+ ], $ this ->pushoverReceiver ->toArray ());
5867 }
5968
6069 /** @test */
6170 public function it_can_add_multiple_devices_to_the_receiver ()
6271 {
63- $ this ->pushoverReceiver ->toDevice ('iphone ' )
72+ $ this ->pushoverReceiver
73+ ->toDevice ('iphone ' )
6474 ->toDevice ('desktop ' )
6575 ->toDevice ('macbook ' );
6676
67- Assert::assertArraySubset (['device ' => 'iphone,desktop,macbook ' ], $ this ->pushoverReceiver ->toArray ());
77+ $ this ->assertEquals ([
78+ 'user ' => 'pushover-key ' ,
79+ 'device ' => 'iphone,desktop,macbook ' ,
80+ ], $ this ->pushoverReceiver ->toArray ());
6881 }
6982
7083 /** @test */
7184 public function it_can_add_an_array_of_devices_to_the_receiver ()
7285 {
7386 $ this ->pushoverReceiver ->toDevice (['iphone ' , 'desktop ' , 'macbook ' ]);
7487
75- Assert::assertArraySubset (['device ' => 'iphone,desktop,macbook ' ], $ this ->pushoverReceiver ->toArray ());
88+ $ this ->assertEquals ([
89+ 'user ' => 'pushover-key ' ,
90+ 'device ' => 'iphone,desktop,macbook ' ,
91+ ], $ this ->pushoverReceiver ->toArray ());
7692 }
7793}
0 commit comments