Skip to content

Commit 8c0abfa

Browse files
patel-vanshmichalsn
andcommitted
apply suggestion
Co-authored-by: Michal Sniatala <michal@sniatala.pl>
1 parent 242a4d1 commit 8c0abfa

1 file changed

Lines changed: 8 additions & 6 deletions

File tree

tests/system/Database/Live/SQLSRV/IncrementTest.php

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,11 @@ public function testIncrementWhenCastTextToIntFalse(): void
4545

4646
$this->assertInstanceOf(Builder::class, $this->db->table('job'));
4747

48-
$this->db->table('job')->castTextToInt = false;
48+
$builder = $this->db->table('job');
4949

50-
$this->db->table('job')
51-
->where('name', 'incremental')
50+
$builder->castTextToInt = false;
51+
52+
$builder->where('name', 'incremental')
5253
->increment('created_at');
5354

5455
$this->seeInDatabase('job', ['name' => 'incremental', 'created_at' => 7]);
@@ -60,10 +61,11 @@ public function testDecrementWhenCastTextToIntFalse(): void
6061

6162
$this->assertInstanceOf(Builder::class, $this->db->table('job'));
6263

63-
$this->db->table('job')->castTextToInt = false;
64+
$builder = $this->db->table('job');
65+
66+
$builder->castTextToInt = false;
6467

65-
$this->db->table('job')
66-
->where('name', 'decremental')
68+
$builder->where('name', 'incremental')
6769
->decrement('created_at');
6870

6971
$this->seeInDatabase('job', ['name' => 'decremental', 'created_at' => 5]);

0 commit comments

Comments
 (0)