insert([ 'notification_id' => 1, 'user_id' => 1, 'is_read' => 0, ]); $service = new NotificationReadService(); $result = $service->markRead(1, 1); $this->assertTrue($result); $this->assertDatabaseHas('user_notifications', [ 'notification_id' => 1, 'user_id' => 1, 'is_read' => 1, ]); } public function test_mark_read_returns_false_when_missing(): void { $service = new NotificationReadService(); $this->assertFalse($service->markRead(1, 99)); } }