Update to laravel 12, other changes.

This commit is contained in:
Simon Pocrnjič
2025-03-25 21:38:24 +01:00
parent 0f8cfd3f16
commit 86a021143a
22 changed files with 2820 additions and 1504 deletions
+31 -2
View File
@@ -9,8 +9,37 @@ class ExampleTest extends TestCase
/**
* A basic test example.
*/
public function test_that_true_is_true(): void
public function test_that_true_is_true(): string
{
$this->assertTrue(true);
$this->assertTrue(false);
return 'first';
}
public function testPushAndPop(): void
{
$stack = [];
$this->assertSame(0, count($stack));
array_push($stack, 'foo');
$this->assertSame('foo', $stack[count($stack)-1]);
$this->assertSame(1, count($stack));
$this->assertSame('foo', array_pop($stack));
$this->assertSame(0, count($stack));
}
public function testDeprecationCanBeExpected(): void
{
$this->expectDeprecation();
// Optionally test that the message is equal to a string
$this->expectDeprecationMessage('foo');
// Or optionally test that the message matches a regular expression
$this->expectDeprecationMessageMatches('/foo/');
\trigger_error('foo', \E_USER_DEPRECATED);
}
}