It seems like assertTrue() must be provided by classes using this trait. How about adding it as abstract method to this trait?
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the ignore-call annotation
23
$this->/** @scrutinizer ignore-call */
24
assertTrue($cache->has($key), "The Octane cache doesn't have the [$key] key set");
Loading history...
24
} else {
25
1
$actual = $cache->get($key);
26
1
$this->assertSame($value, $actual, "Expected cached value [$value], got [$actual] instead");
It seems like assertSame() must be provided by classes using this trait. How about adding it as abstract method to this trait?
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the ignore-call annotation
26
$this->/** @scrutinizer ignore-call */
27
assertSame($value, $actual, "Expected cached value [$value], got [$actual] instead");
Loading history...
27
}
28
29
1
return $this;
30
}
31
32
/**
33
* Assert that the Laravel Octane cache doesn't have the given key set
34
*
35
* @param string $key
36
* @return static
37
*/
38
1
public function assertOctaneCacheMissing(string $key): static
39
{
40
1
$cache = $this->app->cache->store('octane');
41
42
1
$this->assertFalse($cache->has($key), "The Octane cache has the [$key] key set");
It seems like assertFalse() must be provided by classes using this trait. How about adding it as abstract method to this trait?
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the ignore-call annotation
42
$this->/** @scrutinizer ignore-call */
43
assertFalse($cache->has($key), "The Octane cache has the [$key] key set");