• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

tattersoftware / codeigniter4-chat / 7559670250

17 Jan 2024 05:41PM UTC coverage: 70.33%. First build
7559670250

Pull #26

github

web-flow
Merge 391387cc6 into a55dbe47f
Pull Request #26: Bump actions/cache from 3 to 4

128 of 182 relevant lines covered (70.33%)

6.87 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

100.0
/src/Models/ConversationModel.php
1
<?php
2

3
namespace Tatter\Chat\Models;
4

5
use CodeIgniter\Model;
6
use Faker\Generator;
7
use Tatter\Chat\Entities\Conversation;
8

9
class ConversationModel extends Model
10
{
11
    protected $table           = 'chat_conversations';
12
    protected $primaryKey      = 'id';
13
    protected $returnType      = Conversation::class;
14
    protected $useTimestamps   = true;
15
    protected $useSoftDeletes  = true;
16
    protected $skipValidation  = false;
17
    protected $allowedFields   = ['title', 'uid', 'private', 'direct'];
18
    protected $validationRules = ['uid' => 'required'];
19

20
    /**
21
     * Faked data for Fabricator.
22
     */
23
    public function fake(Generator &$faker): Conversation
24
    {
25
        return new Conversation([
15✔
26
            'title' => $faker->company,
15✔
27
            'uid'   => implode('_', $faker->words),
15✔
28
        ]);
15✔
29
    }
30
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc