M3 Integration fixes
This commit is contained in:
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
-3
@@ -17,9 +17,6 @@ class PlatformAdministrationBrowserTest extends DuskTestCase
|
||||
$admin = $this->platformAdminUser();
|
||||
$this->seedPlatformDashboardData();
|
||||
|
||||
$companyName = 'Abbott Logistics ' . uniqid();
|
||||
$billingEmail = 'billing+' . uniqid() . '@abbott.example';
|
||||
|
||||
$this->browse(function (Browser $browser) use ($admin): void {
|
||||
$browser->loginAs($admin)
|
||||
->visit('/admin');
|
||||
|
||||
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
+1
-1
@@ -12,7 +12,7 @@ trait CreatesApplication
|
||||
*/
|
||||
public function createApplication(): Application
|
||||
{
|
||||
$app = require __DIR__ . '/../bootstrap/app.php';
|
||||
$app = require_once __DIR__ . '/../bootstrap/app.php';
|
||||
|
||||
$app->make(Kernel::class)->bootstrap();
|
||||
|
||||
|
||||
Regular → Executable
+6
-3
@@ -10,6 +10,8 @@ use PHPUnit\Framework\Attributes\BeforeClass;
|
||||
|
||||
abstract class DuskTestCase extends BaseTestCase
|
||||
{
|
||||
private const LOOPBACK = '127.0.0.1';
|
||||
|
||||
use CreatesApplication;
|
||||
|
||||
/**
|
||||
@@ -31,7 +33,7 @@ abstract class DuskTestCase extends BaseTestCase
|
||||
if (! static::runningInSail()) {
|
||||
static::ensureChromeDriverBinaryAlias();
|
||||
static::startChromeDriver(['--port=9515']);
|
||||
static::waitForTcpPort('127.0.0.1', 9515, 8.0, 'ChromeDriver');
|
||||
static::waitForTcpPort(self::LOOPBACK, 9515, 8.0, 'ChromeDriver');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -98,7 +100,7 @@ abstract class DuskTestCase extends BaseTestCase
|
||||
$parts = parse_url($url);
|
||||
|
||||
$scheme = $parts['scheme'] ?? 'http';
|
||||
$host = $parts['host'] ?? '127.0.0.1';
|
||||
$host = $parts['host'] ?? self::LOOPBACK;
|
||||
$port = (int) ($parts['port'] ?? ($scheme === 'https' ? 443 : 80));
|
||||
|
||||
$useExternalServer = filter_var(
|
||||
@@ -176,6 +178,7 @@ abstract class DuskTestCase extends BaseTestCase
|
||||
|
||||
if (is_bool($value)) {
|
||||
$filtered[$key] = $value ? 'true' : 'false';
|
||||
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -190,7 +193,7 @@ abstract class DuskTestCase extends BaseTestCase
|
||||
private static function availablePort(int $from, int $to): int
|
||||
{
|
||||
for ($port = $from; $port <= $to; $port++) {
|
||||
if (! static::canConnect('127.0.0.1', $port)) {
|
||||
if (! static::canConnect(self::LOOPBACK, $port)) {
|
||||
return $port;
|
||||
}
|
||||
}
|
||||
|
||||
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
Regular → Executable
-6
@@ -276,10 +276,4 @@ class PlatformAdministrationTest extends TestCase
|
||||
/**
|
||||
* Seed the test session with the matching CSRF token.
|
||||
*/
|
||||
private function withCsrfSession(): self
|
||||
{
|
||||
$this->withSession(['_token' => 'test-token']);
|
||||
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
|
||||
Regular → Executable
-6
@@ -314,10 +314,4 @@ class PlatformPriceCrudTest extends TestCase
|
||||
/**
|
||||
* Seed the test session with the matching CSRF token.
|
||||
*/
|
||||
private function withCsrfSession(): self
|
||||
{
|
||||
$this->withSession(['_token' => 'test-token']);
|
||||
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
|
||||
Regular → Executable
+1
-1
@@ -14,7 +14,7 @@ class ProfileUpdateTest extends TestCase
|
||||
|
||||
public function test_profile_page_is_displayed(): void
|
||||
{
|
||||
$this->actingAs($user = User::factory()->create());
|
||||
$this->actingAs(User::factory()->create());
|
||||
|
||||
$this->get('/settings/profile')->assertOk();
|
||||
}
|
||||
|
||||
Regular → Executable
Regular → Executable
-6
@@ -217,10 +217,4 @@ class WarehouseCrudTest extends TestCase
|
||||
/**
|
||||
* Seed the test session with the matching CSRF token.
|
||||
*/
|
||||
private function withCsrfSession(): self
|
||||
{
|
||||
$this->withSession(['_token' => 'test-token']);
|
||||
|
||||
return $this;
|
||||
}
|
||||
}
|
||||
|
||||
Regular → Executable
Regular → Executable
Regular → Executable
Reference in New Issue
Block a user