mirror of
https://github.com/anonaddy/anonaddy.git
synced 2024-09-20 06:56:02 +08:00
Upgraded to Laravel 11
This commit is contained in:
parent
e7a723df1c
commit
5cf59c4f7d
5
.gitignore
vendored
5
.gitignore
vendored
|
@ -1,3 +1,4 @@
|
|||
/.phpunit.cache
|
||||
/node_modules
|
||||
/public/hot
|
||||
/public/storage
|
||||
|
@ -9,14 +10,18 @@
|
|||
/storage/debugbar
|
||||
/vendor
|
||||
/postfix/vendor
|
||||
/.fleet
|
||||
/.idea
|
||||
/.vscode
|
||||
/.vagrant
|
||||
Homestead.json
|
||||
Homestead.yaml
|
||||
auth.json
|
||||
npm-debug.log
|
||||
yarn-error.log
|
||||
.env
|
||||
.env.backup
|
||||
.env.production
|
||||
.php-cs-fixer.cache
|
||||
.phpunit.result.cache
|
||||
ray.php
|
||||
|
|
|
@ -351,12 +351,24 @@ class ReceiveEmail extends Command
|
|||
// Try to determine the bounce type, HARD, SPAM, SOFT
|
||||
$bounceType = $this->getBounceType($dsn['Diagnostic-code'], $dsn['Status']);
|
||||
|
||||
$diagnosticCode = Str::limit($dsn['Diagnostic-code'], 497);
|
||||
$diagnosticCode = trim(Str::limit($dsn['Diagnostic-code'], 497));
|
||||
} else {
|
||||
$bounceType = null;
|
||||
$diagnosticCode = null;
|
||||
}
|
||||
|
||||
// To sort '5.7.1 (delivery not authorized, message refused)' as status
|
||||
if ($status = $dsn['Status'] ?? null) {
|
||||
|
||||
if (Str::length($status) > 5) {
|
||||
if (is_null($diagnosticCode)) {
|
||||
$diagnosticCode = trim(Str::substr($status, 5, 497));
|
||||
}
|
||||
|
||||
$status = trim(Str::substr($status, 0, 5));
|
||||
}
|
||||
}
|
||||
|
||||
// Get the undelivered message
|
||||
$undeliveredMessage = $attachments->filter(function ($attachment) {
|
||||
return in_array($attachment->getContentType(), ['text/rfc822-headers', 'message/rfc822']);
|
||||
|
@ -394,7 +406,7 @@ class ReceiveEmail extends Command
|
|||
'sender' => $undeliveredMessageHeaders['X-anonaddy-original-sender'] ?? null,
|
||||
'destination' => $bouncedEmailAddress,
|
||||
'email_type' => $emailType,
|
||||
'status' => $dsn['Status'] ?? null,
|
||||
'status' => $status ?? null,
|
||||
'code' => $diagnosticCode,
|
||||
'attempted_at' => $outboundMessage->created_at,
|
||||
]);
|
||||
|
|
|
@ -1,48 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Console;
|
||||
|
||||
use Illuminate\Console\Scheduling\Schedule;
|
||||
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
|
||||
|
||||
class Kernel extends ConsoleKernel
|
||||
{
|
||||
/**
|
||||
* The Artisan commands provided by your application.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $commands = [
|
||||
'App\Console\Commands\ResetBandwidth',
|
||||
];
|
||||
|
||||
/**
|
||||
* Define the application's command schedule.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
protected function schedule(Schedule $schedule)
|
||||
{
|
||||
$schedule->command('anonaddy:reset-bandwidth')->monthlyOn(1, '00:00');
|
||||
$schedule->command('anonaddy:check-domains-sending-verification')->daily();
|
||||
$schedule->command('anonaddy:check-domains-mx-validation')->daily();
|
||||
$schedule->command('anonaddy:clear-failed-deliveries')->daily();
|
||||
$schedule->command('anonaddy:clear-outbound-messages')->everySixHours();
|
||||
$schedule->command('anonaddy:email-users-with-token-expiring-soon')->daily();
|
||||
$schedule->command('auth:clear-resets')->daily();
|
||||
$schedule->command('sanctum:prune-expired --hours=168')->daily();
|
||||
$schedule->command('cache:prune-stale-tags')->hourly();
|
||||
}
|
||||
|
||||
/**
|
||||
* Register the commands for the application.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
protected function commands()
|
||||
{
|
||||
$this->load(__DIR__.'/Commands');
|
||||
|
||||
require base_path('routes/console.php');
|
||||
}
|
||||
}
|
|
@ -1,27 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Exceptions;
|
||||
|
||||
use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler;
|
||||
|
||||
class Handler extends ExceptionHandler
|
||||
{
|
||||
/**
|
||||
* The list of the inputs that are never flashed to the session on validation exceptions.
|
||||
*
|
||||
* @var array<int, string>
|
||||
*/
|
||||
protected $dontFlash = [
|
||||
'current_password',
|
||||
'password',
|
||||
'password_confirmation',
|
||||
];
|
||||
|
||||
/**
|
||||
* Register the exception handling callbacks for the application.
|
||||
*/
|
||||
public function register(): void
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
|
@ -7,7 +7,6 @@ use App\Http\Controllers\Controller;
|
|||
use App\Models\Username;
|
||||
use Illuminate\Foundation\Auth\AuthenticatesUsers;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Support\Facades\Hash;
|
||||
use Illuminate\Support\Facades\Validator;
|
||||
use Illuminate\Validation\ValidationException;
|
||||
use Inertia\Inertia;
|
||||
|
@ -137,20 +136,6 @@ class LoginController extends Controller
|
|||
]);
|
||||
}
|
||||
|
||||
/**
|
||||
* The user has been authenticated.
|
||||
*
|
||||
* @param mixed $user
|
||||
* @return mixed
|
||||
*/
|
||||
protected function authenticated(Request $request, $user)
|
||||
{
|
||||
// Check if the user's password needs rehashing
|
||||
if (Hash::needsRehash($user->password)) {
|
||||
$user->update(['password' => Hash::make($request->password)]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* The user has logged out of the application.
|
||||
*
|
||||
|
|
|
@ -44,7 +44,7 @@ class VerificationController extends Controller
|
|||
*/
|
||||
public function __construct()
|
||||
{
|
||||
$this->middleware('auth')->except('verify');
|
||||
$this->middleware('auth');
|
||||
$this->middleware('signed')->only('verify');
|
||||
$this->middleware('throttle:1,1')->only('resend');
|
||||
$this->middleware('throttle:6,1')->only('verify');
|
||||
|
|
|
@ -1,71 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http;
|
||||
|
||||
use Illuminate\Foundation\Http\Kernel as HttpKernel;
|
||||
|
||||
class Kernel extends HttpKernel
|
||||
{
|
||||
/**
|
||||
* The application's global HTTP middleware stack.
|
||||
*
|
||||
* These middleware are run during every request to your application.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $middleware = [
|
||||
// \App\Http\Middleware\TrustHosts::class,
|
||||
\App\Http\Middleware\TrustProxies::class,
|
||||
\Illuminate\Http\Middleware\HandleCors::class,
|
||||
\App\Http\Middleware\PreventRequestsDuringMaintenance::class,
|
||||
\Illuminate\Foundation\Http\Middleware\ValidatePostSize::class,
|
||||
\App\Http\Middleware\TrimStrings::class,
|
||||
\Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull::class,
|
||||
];
|
||||
|
||||
/**
|
||||
* The application's route middleware groups.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $middlewareGroups = [
|
||||
'web' => [
|
||||
\App\Http\Middleware\EncryptCookies::class,
|
||||
\Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class,
|
||||
\Illuminate\Session\Middleware\StartSession::class,
|
||||
\Illuminate\Session\Middleware\AuthenticateSession::class,
|
||||
\Illuminate\View\Middleware\ShareErrorsFromSession::class,
|
||||
\App\Http\Middleware\VerifyCsrfToken::class,
|
||||
\Illuminate\Routing\Middleware\SubstituteBindings::class,
|
||||
\App\Http\Middleware\HandleInertiaRequests::class, // Must be the last item!
|
||||
],
|
||||
|
||||
'api' => [
|
||||
\Laravel\Sanctum\Http\Middleware\EnsureFrontendRequestsAreStateful::class,
|
||||
\Illuminate\Routing\Middleware\ThrottleRequests::class.':api',
|
||||
\Illuminate\Routing\Middleware\SubstituteBindings::class,
|
||||
],
|
||||
];
|
||||
|
||||
/**
|
||||
* The application's middleware aliases.
|
||||
*
|
||||
* Aliases may be used instead of class names to conveniently assign middleware to routes and groups.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $middlewareAliases = [
|
||||
'auth' => \App\Http\Middleware\Authenticate::class,
|
||||
'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class,
|
||||
'auth.session' => \Illuminate\Session\Middleware\AuthenticateSession::class,
|
||||
'cache.headers' => \Illuminate\Http\Middleware\SetCacheHeaders::class,
|
||||
'can' => \Illuminate\Auth\Middleware\Authorize::class,
|
||||
'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class,
|
||||
'password.confirm' => \Illuminate\Auth\Middleware\RequirePassword::class,
|
||||
'signed' => \Illuminate\Routing\Middleware\ValidateSignature::class,
|
||||
'throttle' => \Illuminate\Routing\Middleware\ThrottleRequestsWithRedis::class,
|
||||
'verified' => \Illuminate\Auth\Middleware\EnsureEmailIsVerified::class,
|
||||
'2fa' => \App\Http\Middleware\VerifyTwoFactorAuth::class,
|
||||
'webauthn' => \App\Http\Middleware\VerifyWebauthn::class,
|
||||
];
|
||||
}
|
|
@ -1,17 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Illuminate\Auth\Middleware\Authenticate as Middleware;
|
||||
use Illuminate\Http\Request;
|
||||
|
||||
class Authenticate extends Middleware
|
||||
{
|
||||
/**
|
||||
* Get the path the user should be redirected to when they are not authenticated.
|
||||
*/
|
||||
protected function redirectTo(Request $request): ?string
|
||||
{
|
||||
return $request->expectsJson() ? null : route('login');
|
||||
}
|
||||
}
|
|
@ -1,17 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Illuminate\Cookie\Middleware\EncryptCookies as Middleware;
|
||||
|
||||
class EncryptCookies extends Middleware
|
||||
{
|
||||
/**
|
||||
* The names of the cookies that should not be encrypted.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $except = [
|
||||
//
|
||||
];
|
||||
}
|
|
@ -1,17 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Illuminate\Foundation\Http\Middleware\PreventRequestsDuringMaintenance as Middleware;
|
||||
|
||||
class PreventRequestsDuringMaintenance extends Middleware
|
||||
{
|
||||
/**
|
||||
* The URIs that should be reachable while maintenance mode is enabled.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $except = [
|
||||
//
|
||||
];
|
||||
}
|
|
@ -1,30 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use App\Providers\RouteServiceProvider;
|
||||
use Closure;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Support\Facades\Auth;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
|
||||
class RedirectIfAuthenticated
|
||||
{
|
||||
/**
|
||||
* Handle an incoming request.
|
||||
*
|
||||
* @param \Closure(\Illuminate\Http\Request): (\Symfony\Component\HttpFoundation\Response) $next
|
||||
*/
|
||||
public function handle(Request $request, Closure $next, string ...$guards): Response
|
||||
{
|
||||
$guards = empty($guards) ? [null] : $guards;
|
||||
|
||||
foreach ($guards as $guard) {
|
||||
if (Auth::guard($guard)->check()) {
|
||||
return redirect(RouteServiceProvider::HOME);
|
||||
}
|
||||
}
|
||||
|
||||
return $next($request);
|
||||
}
|
||||
}
|
|
@ -1,18 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Illuminate\Foundation\Http\Middleware\TrimStrings as Middleware;
|
||||
|
||||
class TrimStrings extends Middleware
|
||||
{
|
||||
/**
|
||||
* The names of the attributes that should not be trimmed.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $except = [
|
||||
'password',
|
||||
'password_confirmation',
|
||||
];
|
||||
}
|
|
@ -1,28 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Illuminate\Http\Middleware\TrustProxies as Middleware;
|
||||
use Illuminate\Http\Request;
|
||||
|
||||
class TrustProxies extends Middleware
|
||||
{
|
||||
/**
|
||||
* The trusted proxies for this application.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $proxies;
|
||||
|
||||
/**
|
||||
* The headers that should be used to detect proxies.
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
protected $headers =
|
||||
Request::HEADER_X_FORWARDED_FOR |
|
||||
Request::HEADER_X_FORWARDED_HOST |
|
||||
Request::HEADER_X_FORWARDED_PORT |
|
||||
Request::HEADER_X_FORWARDED_PROTO |
|
||||
Request::HEADER_X_FORWARDED_AWS_ELB;
|
||||
}
|
|
@ -1,24 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Illuminate\Foundation\Http\Middleware\VerifyCsrfToken as Middleware;
|
||||
|
||||
class VerifyCsrfToken extends Middleware
|
||||
{
|
||||
/**
|
||||
* Indicates whether the XSRF-TOKEN cookie should be set on the response.
|
||||
*
|
||||
* @var bool
|
||||
*/
|
||||
protected $addHttpCookie = true;
|
||||
|
||||
/**
|
||||
* The URIs that should be excluded from CSRF verification.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $except = [
|
||||
'api/auth/login',
|
||||
];
|
||||
}
|
|
@ -23,7 +23,6 @@ class AppServiceProvider extends ServiceProvider
|
|||
*/
|
||||
public function register(): void
|
||||
{
|
||||
Sanctum::ignoreMigrations();
|
||||
Webauthn::registerViewResponseUsing(RegisterViewResponse::class);
|
||||
Webauthn::registerSuccessResponseUsing(RegisterSuccessResponse::class);
|
||||
Webauthn::loginViewResponseUsing(LoginViewResponse::class);
|
||||
|
|
52
artisan
52
artisan
|
@ -1,53 +1,15 @@
|
|||
#!/usr/bin/env php
|
||||
<?php
|
||||
|
||||
use Symfony\Component\Console\Input\ArgvInput;
|
||||
|
||||
define('LARAVEL_START', microtime(true));
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Register The Auto Loader
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Composer provides a convenient, automatically generated class loader
|
||||
| for our application. We just need to utilize it! We'll require it
|
||||
| into the script here so that we do not have to worry about the
|
||||
| loading of any our classes "manually". Feels great to relax.
|
||||
|
|
||||
*/
|
||||
|
||||
// Register the Composer autoloader...
|
||||
require __DIR__.'/vendor/autoload.php';
|
||||
|
||||
$app = require_once __DIR__.'/bootstrap/app.php';
|
||||
// Bootstrap Laravel and handle the command...
|
||||
$status = (require_once __DIR__.'/bootstrap/app.php')
|
||||
->handleCommand(new ArgvInput);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Run The Artisan Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When we run the console application, the current CLI command will be
|
||||
| executed in this console and the response sent back to a terminal
|
||||
| or another output device for the developers. Here goes nothing!
|
||||
|
|
||||
*/
|
||||
|
||||
$kernel = $app->make(Illuminate\Contracts\Console\Kernel::class);
|
||||
|
||||
$status = $kernel->handle(
|
||||
$input = new Symfony\Component\Console\Input\ArgvInput,
|
||||
new Symfony\Component\Console\Output\ConsoleOutput
|
||||
);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Shutdown The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Once Artisan has finished running, we will fire off the shutdown events
|
||||
| so that any final work may be done by the application before we shut
|
||||
| down the process. This is the last thing to happen to the request.
|
||||
|
|
||||
*/
|
||||
|
||||
$kernel->terminate($input, $status);
|
||||
|
||||
exit($status);
|
||||
exit($status);
|
|
@ -1,55 +1,52 @@
|
|||
<?php
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Create The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The first thing we will do is create a new Laravel application instance
|
||||
| which serves as the "glue" for all the components of Laravel, and is
|
||||
| the IoC container for the system binding all of the various parts.
|
||||
|
|
||||
*/
|
||||
use Illuminate\Foundation\Application;
|
||||
use Illuminate\Foundation\Configuration\Exceptions;
|
||||
use Illuminate\Foundation\Configuration\Middleware;
|
||||
|
||||
$app = new Illuminate\Foundation\Application(
|
||||
$_ENV['APP_BASE_PATH'] ?? dirname(__DIR__)
|
||||
);
|
||||
return Application::configure(basePath: dirname(__DIR__))
|
||||
->withRouting(
|
||||
web: __DIR__.'/../routes/web.php',
|
||||
commands: __DIR__.'/../routes/console.php',
|
||||
api: __DIR__.'/../routes/api.php',
|
||||
)
|
||||
->withMiddleware(function (Middleware $middleware) {
|
||||
$middleware->throttleWithRedis();
|
||||
$middleware->throttleApi('api', true);
|
||||
$middleware->authenticateSessions();
|
||||
$middleware->statefulApi();
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Bind Important Interfaces
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Next, we need to bind some important interfaces into the container so
|
||||
| we will be able to resolve them when needed. The kernels serve the
|
||||
| incoming requests to this application from both the web and CLI.
|
||||
|
|
||||
*/
|
||||
$middleware->trimStrings(
|
||||
except: [
|
||||
'current',
|
||||
'current_password',
|
||||
'password',
|
||||
'password_confirmation',
|
||||
'current_password_2fa',
|
||||
]
|
||||
);
|
||||
|
||||
$app->singleton(
|
||||
Illuminate\Contracts\Http\Kernel::class,
|
||||
App\Http\Kernel::class
|
||||
);
|
||||
$middleware->validateCsrfTokens(
|
||||
except: [
|
||||
'api/auth/login',
|
||||
]
|
||||
);
|
||||
|
||||
$app->singleton(
|
||||
Illuminate\Contracts\Console\Kernel::class,
|
||||
App\Console\Kernel::class
|
||||
);
|
||||
$middleware->web(append: [
|
||||
\App\Http\Middleware\HandleInertiaRequests::class, // Must be the last item!
|
||||
]);
|
||||
|
||||
$app->singleton(
|
||||
Illuminate\Contracts\Debug\ExceptionHandler::class,
|
||||
App\Exceptions\Handler::class
|
||||
);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Return The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This script returns the application instance. The instance is given to
|
||||
| the calling script so we can separate the building of the instances
|
||||
| from the actual running of the application and sending responses.
|
||||
|
|
||||
*/
|
||||
|
||||
return $app;
|
||||
$middleware->alias([
|
||||
'2fa' => \App\Http\Middleware\VerifyTwoFactorAuth::class,
|
||||
'webauthn' => \App\Http\Middleware\VerifyWebauthn::class,
|
||||
]);
|
||||
})
|
||||
->withExceptions(function (Exceptions $exceptions) {
|
||||
$exceptions->dontFlash([
|
||||
'current',
|
||||
'current_password',
|
||||
'password',
|
||||
'password_confirmation',
|
||||
'current_password_2fa',
|
||||
]);
|
||||
})->create();
|
||||
|
|
11
bootstrap/providers.php
Normal file
11
bootstrap/providers.php
Normal file
|
@ -0,0 +1,11 @@
|
|||
<?php
|
||||
|
||||
return [
|
||||
App\Providers\AppServiceProvider::class,
|
||||
App\Providers\AuthServiceProvider::class,
|
||||
// App\Providers\BroadcastServiceProvider::class,
|
||||
App\Providers\EventServiceProvider::class,
|
||||
App\Providers\RouteServiceProvider::class,
|
||||
App\Providers\HelperServiceProvider::class,
|
||||
App\Providers\CustomMailServiceProvider::class,
|
||||
];
|
|
@ -9,13 +9,12 @@
|
|||
"require": {
|
||||
"php": "^8.2",
|
||||
"asbiin/laravel-webauthn": "^4.0.0",
|
||||
"bacon/bacon-qr-code": "^2.0",
|
||||
"bacon/bacon-qr-code": "^3.0",
|
||||
"chillerlan/php-qrcode": "^5.0",
|
||||
"doctrine/dbal": "^3.0",
|
||||
"guzzlehttp/guzzle": "^7.2",
|
||||
"inertiajs/inertia-laravel": "^0.6.9",
|
||||
"laravel/framework": "^10.0",
|
||||
"laravel/sanctum": "^3.2",
|
||||
"inertiajs/inertia-laravel": "^1.0",
|
||||
"laravel/framework": "^11.0",
|
||||
"laravel/sanctum": "^4.0",
|
||||
"laravel/tinker": "^2.7",
|
||||
"laravel/ui": "^4.0",
|
||||
"maatwebsite/excel": "^3.1",
|
||||
|
@ -29,8 +28,8 @@
|
|||
"fakerphp/faker": "^1.9.1",
|
||||
"laravel/pint": "^1.2",
|
||||
"mockery/mockery": "^1.4.4",
|
||||
"nunomaduro/collision": "^7.0",
|
||||
"phpunit/phpunit": "^10.0",
|
||||
"nunomaduro/collision": "^8.1",
|
||||
"phpunit/phpunit": "^11.0",
|
||||
"spatie/laravel-ignition": "^2.0",
|
||||
"spatie/laravel-ray": "^1.29"
|
||||
},
|
||||
|
|
1578
composer.lock
generated
1578
composer.lock
generated
File diff suppressed because it is too large
Load diff
|
@ -1,8 +1,5 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Facade;
|
||||
use Illuminate\Support\ServiceProvider;
|
||||
|
||||
return [
|
||||
|
||||
/*
|
||||
|
@ -57,8 +54,6 @@ return [
|
|||
|
||||
'url' => env('APP_URL', 'http://localhost'),
|
||||
|
||||
'asset_url' => env('ASSET_URL'),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Application Timezone
|
||||
|
@ -124,6 +119,12 @@ return [
|
|||
|
||||
'key' => env('APP_KEY'),
|
||||
|
||||
'previous_keys' => [
|
||||
...array_filter(
|
||||
explode(',', env('APP_PREVIOUS_KEYS', ''))
|
||||
),
|
||||
],
|
||||
|
||||
'cipher' => 'AES-256-CBC',
|
||||
|
||||
/*
|
||||
|
@ -140,57 +141,8 @@ return [
|
|||
*/
|
||||
|
||||
'maintenance' => [
|
||||
'driver' => 'file',
|
||||
// 'store' => 'redis',
|
||||
'driver' => env('APP_MAINTENANCE_DRIVER', 'file'),
|
||||
'store' => env('APP_MAINTENANCE_STORE', 'database'),
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Autoloaded Service Providers
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| The service providers listed here will be automatically loaded on the
|
||||
| request to your application. Feel free to add your own services to
|
||||
| this array to grant expanded functionality to your applications.
|
||||
|
|
||||
*/
|
||||
|
||||
'providers' => ServiceProvider::defaultProviders()->merge([
|
||||
|
||||
/*
|
||||
* Laravel Framework Service Providers...
|
||||
*/
|
||||
|
||||
/*
|
||||
* Package Service Providers...
|
||||
*/
|
||||
|
||||
/*
|
||||
* Application Service Providers...
|
||||
*/
|
||||
App\Providers\AppServiceProvider::class,
|
||||
App\Providers\AuthServiceProvider::class,
|
||||
// App\Providers\BroadcastServiceProvider::class,
|
||||
App\Providers\EventServiceProvider::class,
|
||||
App\Providers\RouteServiceProvider::class,
|
||||
App\Providers\HelperServiceProvider::class,
|
||||
App\Providers\CustomMailServiceProvider::class,
|
||||
|
||||
])->toArray(),
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Class Aliases
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This array of class aliases will be registered when this application
|
||||
| is started. However, feel free to register as many as you wish as
|
||||
| the aliases are "lazy" loaded so they don't hinder performance.
|
||||
|
|
||||
*/
|
||||
|
||||
'aliases' => Facade::defaultAliases()->merge([
|
||||
// 'Example' => App\Facades\Example::class,
|
||||
])->toArray(),
|
||||
|
||||
];
|
||||
|
|
|
@ -61,6 +61,26 @@ return [
|
|||
]) : [],
|
||||
],
|
||||
|
||||
'mariadb' => [
|
||||
'driver' => 'mariadb',
|
||||
'url' => env('DB_URL'),
|
||||
'host' => env('DB_HOST', '127.0.0.1'),
|
||||
'port' => env('DB_PORT', '3306'),
|
||||
'database' => env('DB_DATABASE', 'laravel'),
|
||||
'username' => env('DB_USERNAME', 'root'),
|
||||
'password' => env('DB_PASSWORD', ''),
|
||||
'unix_socket' => env('DB_SOCKET', ''),
|
||||
'charset' => env('DB_CHARSET', 'utf8mb4'),
|
||||
'collation' => env('DB_COLLATION', 'utf8mb4_unicode_ci'),
|
||||
'prefix' => '',
|
||||
'prefix_indexes' => true,
|
||||
'strict' => true,
|
||||
'engine' => null,
|
||||
'options' => extension_loaded('pdo_mysql') ? array_filter([
|
||||
PDO::MYSQL_ATTR_SSL_CA => env('MYSQL_ATTR_SSL_CA'),
|
||||
]) : [],
|
||||
],
|
||||
|
||||
'pgsql' => [
|
||||
'driver' => 'pgsql',
|
||||
'host' => env('DB_HOST', '127.0.0.1'),
|
||||
|
@ -102,7 +122,10 @@ return [
|
|||
|
|
||||
*/
|
||||
|
||||
'migrations' => 'migrations',
|
||||
'migrations' => [
|
||||
'table' => 'migrations',
|
||||
'update_date_on_publish' => true,
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
|
@ -30,6 +30,7 @@ return [
|
|||
|
||||
'bcrypt' => [
|
||||
'rounds' => env('BCRYPT_ROUNDS', 12),
|
||||
'verify' => env('HASH_VERIFY', true),
|
||||
],
|
||||
|
||||
/*
|
||||
|
@ -44,9 +45,23 @@ return [
|
|||
*/
|
||||
|
||||
'argon' => [
|
||||
'memory' => 1024,
|
||||
'threads' => 2,
|
||||
'time' => 2,
|
||||
'memory' => env('ARGON_MEMORY', 65536),
|
||||
'threads' => env('ARGON_THREADS', 1),
|
||||
'time' => env('ARGON_TIME', 4),
|
||||
'verify' => env('HASH_VERIFY', true),
|
||||
],
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Rehash On Login
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Setting this option to true will tell Laravel to automatically rehash
|
||||
| the user's password during login if the configured work factor for
|
||||
| the algorithm has changed, allowing graceful upgrades of hashes.
|
||||
|
|
||||
*/
|
||||
|
||||
'rehash_on_login' => true,
|
||||
|
||||
];
|
||||
|
|
|
@ -76,8 +76,9 @@ return [
|
|||
*/
|
||||
|
||||
'middleware' => [
|
||||
'verify_csrf_token' => App\Http\Middleware\VerifyCsrfToken::class,
|
||||
'encrypt_cookies' => App\Http\Middleware\EncryptCookies::class,
|
||||
'authenticate_session' => Laravel\Sanctum\Http\Middleware\AuthenticateSession::class,
|
||||
'encrypt_cookies' => Illuminate\Cookie\Middleware\EncryptCookies::class,
|
||||
'validate_csrf_token' => Illuminate\Foundation\Http\Middleware\ValidateCsrfToken::class,
|
||||
],
|
||||
|
||||
];
|
||||
|
|
|
@ -70,6 +70,7 @@ class MoveAccountUsernameToUsernamesTable extends Migration
|
|||
|
||||
// Drop the username and catch_all column from the users table
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
$table->dropIndex('users_username_unique');
|
||||
$table->dropColumn('username');
|
||||
});
|
||||
// Separate call to dropColumn since SQLite doesn't support multiple calls
|
||||
|
|
219
package-lock.json
generated
219
package-lock.json
generated
|
@ -32,7 +32,7 @@
|
|||
},
|
||||
"devDependencies": {
|
||||
"@vitejs/plugin-vue": "^5.0.0",
|
||||
"css-loader": "^6.0.0",
|
||||
"css-loader": "^7.0.0",
|
||||
"husky": "^9.0.0",
|
||||
"laravel-vite-plugin": "^1.0.0",
|
||||
"lint-staged": "^15.0.0",
|
||||
|
@ -442,9 +442,9 @@
|
|||
}
|
||||
},
|
||||
"node_modules/@headlessui/vue": {
|
||||
"version": "1.7.21",
|
||||
"resolved": "https://registry.npmjs.org/@headlessui/vue/-/vue-1.7.21.tgz",
|
||||
"integrity": "sha512-95cPFP5X9luB8/+smPENFv0ruaotT6epFnqK9EKldX2YpNkYM/qkN44oFoqQo+higlCAxDK5Pkg2E3FuD1Anyg==",
|
||||
"version": "1.7.22",
|
||||
"resolved": "https://registry.npmjs.org/@headlessui/vue/-/vue-1.7.22.tgz",
|
||||
"integrity": "sha512-Hoffjoolq1rY+LOfJ+B/OvkhuBXXBFgd8oBlN+l1TApma2dB0En0ucFZrwQtb33SmcCqd32EQd0y07oziXWNYg==",
|
||||
"dependencies": {
|
||||
"@tanstack/vue-virtual": "^3.0.0-beta.60"
|
||||
},
|
||||
|
@ -723,9 +723,9 @@
|
|||
"peer": true
|
||||
},
|
||||
"node_modules/@types/node": {
|
||||
"version": "20.12.8",
|
||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.12.8.tgz",
|
||||
"integrity": "sha512-NU0rJLJnshZWdE/097cdCBbyW1h4hEg0xpovcoAQYHl8dnEyp/NAOiE45pvc+Bd1Dt+2r94v2eGFpQJ4R7g+2w==",
|
||||
"version": "20.12.12",
|
||||
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.12.12.tgz",
|
||||
"integrity": "sha512-eWLDGF/FOSPtAvEqeRAQ4C8LSA7M1I7i0ky1I8U7kD1J5ITyW3AsRhQrKVoWf5pFKZ2kILsEGJhsI9r93PYnOw==",
|
||||
"peer": true,
|
||||
"dependencies": {
|
||||
"undici-types": "~5.26.4"
|
||||
|
@ -745,36 +745,36 @@
|
|||
}
|
||||
},
|
||||
"node_modules/@vue/compiler-core": {
|
||||
"version": "3.4.26",
|
||||
"resolved": "https://registry.npmjs.org/@vue/compiler-core/-/compiler-core-3.4.26.tgz",
|
||||
"integrity": "sha512-N9Vil6Hvw7NaiyFUFBPXrAyETIGlQ8KcFMkyk6hW1Cl6NvoqvP+Y8p1Eqvx+UdqsnrnI9+HMUEJegzia3mhXmQ==",
|
||||
"version": "3.4.27",
|
||||
"resolved": "https://registry.npmjs.org/@vue/compiler-core/-/compiler-core-3.4.27.tgz",
|
||||
"integrity": "sha512-E+RyqY24KnyDXsCuQrI+mlcdW3ALND6U7Gqa/+bVwbcpcR3BRRIckFoz7Qyd4TTlnugtwuI7YgjbvsLmxb+yvg==",
|
||||
"dependencies": {
|
||||
"@babel/parser": "^7.24.4",
|
||||
"@vue/shared": "3.4.26",
|
||||
"@vue/shared": "3.4.27",
|
||||
"entities": "^4.5.0",
|
||||
"estree-walker": "^2.0.2",
|
||||
"source-map-js": "^1.2.0"
|
||||
}
|
||||
},
|
||||
"node_modules/@vue/compiler-dom": {
|
||||
"version": "3.4.26",
|
||||
"resolved": "https://registry.npmjs.org/@vue/compiler-dom/-/compiler-dom-3.4.26.tgz",
|
||||
"integrity": "sha512-4CWbR5vR9fMg23YqFOhr6t6WB1Fjt62d6xdFPyj8pxrYub7d+OgZaObMsoxaF9yBUHPMiPFK303v61PwAuGvZA==",
|
||||
"version": "3.4.27",
|
||||
"resolved": "https://registry.npmjs.org/@vue/compiler-dom/-/compiler-dom-3.4.27.tgz",
|
||||
"integrity": "sha512-kUTvochG/oVgE1w5ViSr3KUBh9X7CWirebA3bezTbB5ZKBQZwR2Mwj9uoSKRMFcz4gSMzzLXBPD6KpCLb9nvWw==",
|
||||
"dependencies": {
|
||||
"@vue/compiler-core": "3.4.26",
|
||||
"@vue/shared": "3.4.26"
|
||||
"@vue/compiler-core": "3.4.27",
|
||||
"@vue/shared": "3.4.27"
|
||||
}
|
||||
},
|
||||
"node_modules/@vue/compiler-sfc": {
|
||||
"version": "3.4.26",
|
||||
"resolved": "https://registry.npmjs.org/@vue/compiler-sfc/-/compiler-sfc-3.4.26.tgz",
|
||||
"integrity": "sha512-It1dp+FAOCgluYSVYlDn5DtZBxk1NCiJJfu2mlQqa/b+k8GL6NG/3/zRbJnHdhV2VhxFghaDq5L4K+1dakW6cw==",
|
||||
"version": "3.4.27",
|
||||
"resolved": "https://registry.npmjs.org/@vue/compiler-sfc/-/compiler-sfc-3.4.27.tgz",
|
||||
"integrity": "sha512-nDwntUEADssW8e0rrmE0+OrONwmRlegDA1pD6QhVeXxjIytV03yDqTey9SBDiALsvAd5U4ZrEKbMyVXhX6mCGA==",
|
||||
"dependencies": {
|
||||
"@babel/parser": "^7.24.4",
|
||||
"@vue/compiler-core": "3.4.26",
|
||||
"@vue/compiler-dom": "3.4.26",
|
||||
"@vue/compiler-ssr": "3.4.26",
|
||||
"@vue/shared": "3.4.26",
|
||||
"@vue/compiler-core": "3.4.27",
|
||||
"@vue/compiler-dom": "3.4.27",
|
||||
"@vue/compiler-ssr": "3.4.27",
|
||||
"@vue/shared": "3.4.27",
|
||||
"estree-walker": "^2.0.2",
|
||||
"magic-string": "^0.30.10",
|
||||
"postcss": "^8.4.38",
|
||||
|
@ -782,57 +782,57 @@
|
|||
}
|
||||
},
|
||||
"node_modules/@vue/compiler-ssr": {
|
||||
"version": "3.4.26",
|
||||
"resolved": "https://registry.npmjs.org/@vue/compiler-ssr/-/compiler-ssr-3.4.26.tgz",
|
||||
"integrity": "sha512-FNwLfk7LlEPRY/g+nw2VqiDKcnDTVdCfBREekF8X74cPLiWHUX6oldktf/Vx28yh4STNy7t+/yuLoMBBF7YDiQ==",
|
||||
"version": "3.4.27",
|
||||
"resolved": "https://registry.npmjs.org/@vue/compiler-ssr/-/compiler-ssr-3.4.27.tgz",
|
||||
"integrity": "sha512-CVRzSJIltzMG5FcidsW0jKNQnNRYC8bT21VegyMMtHmhW3UOI7knmUehzswXLrExDLE6lQCZdrhD4ogI7c+vuw==",
|
||||
"dependencies": {
|
||||
"@vue/compiler-dom": "3.4.26",
|
||||
"@vue/shared": "3.4.26"
|
||||
"@vue/compiler-dom": "3.4.27",
|
||||
"@vue/shared": "3.4.27"
|
||||
}
|
||||
},
|
||||
"node_modules/@vue/reactivity": {
|
||||
"version": "3.4.26",
|
||||
"resolved": "https://registry.npmjs.org/@vue/reactivity/-/reactivity-3.4.26.tgz",
|
||||
"integrity": "sha512-E/ynEAu/pw0yotJeLdvZEsp5Olmxt+9/WqzvKff0gE67tw73gmbx6tRkiagE/eH0UCubzSlGRebCbidB1CpqZQ==",
|
||||
"version": "3.4.27",
|
||||
"resolved": "https://registry.npmjs.org/@vue/reactivity/-/reactivity-3.4.27.tgz",
|
||||
"integrity": "sha512-kK0g4NknW6JX2yySLpsm2jlunZJl2/RJGZ0H9ddHdfBVHcNzxmQ0sS0b09ipmBoQpY8JM2KmUw+a6sO8Zo+zIA==",
|
||||
"dependencies": {
|
||||
"@vue/shared": "3.4.26"
|
||||
"@vue/shared": "3.4.27"
|
||||
}
|
||||
},
|
||||
"node_modules/@vue/runtime-core": {
|
||||
"version": "3.4.26",
|
||||
"resolved": "https://registry.npmjs.org/@vue/runtime-core/-/runtime-core-3.4.26.tgz",
|
||||
"integrity": "sha512-AFJDLpZvhT4ujUgZSIL9pdNcO23qVFh7zWCsNdGQBw8ecLNxOOnPcK9wTTIYCmBJnuPHpukOwo62a2PPivihqw==",
|
||||
"version": "3.4.27",
|
||||
"resolved": "https://registry.npmjs.org/@vue/runtime-core/-/runtime-core-3.4.27.tgz",
|
||||
"integrity": "sha512-7aYA9GEbOOdviqVvcuweTLe5Za4qBZkUY7SvET6vE8kyypxVgaT1ixHLg4urtOlrApdgcdgHoTZCUuTGap/5WA==",
|
||||
"dependencies": {
|
||||
"@vue/reactivity": "3.4.26",
|
||||
"@vue/shared": "3.4.26"
|
||||
"@vue/reactivity": "3.4.27",
|
||||
"@vue/shared": "3.4.27"
|
||||
}
|
||||
},
|
||||
"node_modules/@vue/runtime-dom": {
|
||||
"version": "3.4.26",
|
||||
"resolved": "https://registry.npmjs.org/@vue/runtime-dom/-/runtime-dom-3.4.26.tgz",
|
||||
"integrity": "sha512-UftYA2hUXR2UOZD/Fc3IndZuCOOJgFxJsWOxDkhfVcwLbsfh2CdXE2tG4jWxBZuDAs9J9PzRTUFt1PgydEtItw==",
|
||||
"version": "3.4.27",
|
||||
"resolved": "https://registry.npmjs.org/@vue/runtime-dom/-/runtime-dom-3.4.27.tgz",
|
||||
"integrity": "sha512-ScOmP70/3NPM+TW9hvVAz6VWWtZJqkbdf7w6ySsws+EsqtHvkhxaWLecrTorFxsawelM5Ys9FnDEMt6BPBDS0Q==",
|
||||
"dependencies": {
|
||||
"@vue/runtime-core": "3.4.26",
|
||||
"@vue/shared": "3.4.26",
|
||||
"@vue/runtime-core": "3.4.27",
|
||||
"@vue/shared": "3.4.27",
|
||||
"csstype": "^3.1.3"
|
||||
}
|
||||
},
|
||||
"node_modules/@vue/server-renderer": {
|
||||
"version": "3.4.26",
|
||||
"resolved": "https://registry.npmjs.org/@vue/server-renderer/-/server-renderer-3.4.26.tgz",
|
||||
"integrity": "sha512-xoGAqSjYDPGAeRWxeoYwqJFD/gw7mpgzOvSxEmjWaFO2rE6qpbD1PC172YRpvKhrihkyHJkNDADFXTfCyVGhKw==",
|
||||
"version": "3.4.27",
|
||||
"resolved": "https://registry.npmjs.org/@vue/server-renderer/-/server-renderer-3.4.27.tgz",
|
||||
"integrity": "sha512-dlAMEuvmeA3rJsOMJ2J1kXU7o7pOxgsNHVr9K8hB3ImIkSuBrIdy0vF66h8gf8Tuinf1TK3mPAz2+2sqyf3KzA==",
|
||||
"dependencies": {
|
||||
"@vue/compiler-ssr": "3.4.26",
|
||||
"@vue/shared": "3.4.26"
|
||||
"@vue/compiler-ssr": "3.4.27",
|
||||
"@vue/shared": "3.4.27"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"vue": "3.4.26"
|
||||
"vue": "3.4.27"
|
||||
}
|
||||
},
|
||||
"node_modules/@vue/shared": {
|
||||
"version": "3.4.26",
|
||||
"resolved": "https://registry.npmjs.org/@vue/shared/-/shared-3.4.26.tgz",
|
||||
"integrity": "sha512-Fg4zwR0GNnjzodMt3KRy2AWGMKQXByl56+4HjN87soxLNU9P5xcJkstAlIeEF3cU6UYOzmJl1tV0dVPGIljCnQ=="
|
||||
"version": "3.4.27",
|
||||
"resolved": "https://registry.npmjs.org/@vue/shared/-/shared-3.4.27.tgz",
|
||||
"integrity": "sha512-DL3NmY2OFlqmYYrzp39yi3LDkKxa5vZVwxWdQ3rG0ekuWscHraeIbnI8t+aZK7qhYqEqWKTUdijadunb9pnrgA=="
|
||||
},
|
||||
"node_modules/@vueform/multiselect": {
|
||||
"version": "2.6.7",
|
||||
|
@ -1269,9 +1269,9 @@
|
|||
}
|
||||
},
|
||||
"node_modules/caniuse-lite": {
|
||||
"version": "1.0.30001615",
|
||||
"resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001615.tgz",
|
||||
"integrity": "sha512-1IpazM5G3r38meiae0bHRnPhz+CBQ3ZLqbQMtrg+AsTPKAXgW38JNsXkyZ+v8waCsDmPq87lmfun5Q2AGysNEQ==",
|
||||
"version": "1.0.30001618",
|
||||
"resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001618.tgz",
|
||||
"integrity": "sha512-p407+D1tIkDvsEAPS22lJxLQQaG8OTBEqo0KhzfABGk0TU4juBNDSfH0hyAp/HRyx+M8L17z/ltyhxh27FTfQg==",
|
||||
"funding": [
|
||||
{
|
||||
"type": "opencollective",
|
||||
|
@ -1462,9 +1462,9 @@
|
|||
}
|
||||
},
|
||||
"node_modules/css-loader": {
|
||||
"version": "6.11.0",
|
||||
"resolved": "https://registry.npmjs.org/css-loader/-/css-loader-6.11.0.tgz",
|
||||
"integrity": "sha512-CTJ+AEQJjq5NzLga5pE39qdiSV56F8ywCIsqNIRF0r7BDgWsN25aazToqAFg7ZrtA/U016xudB3ffgweORxX7g==",
|
||||
"version": "7.1.1",
|
||||
"resolved": "https://registry.npmjs.org/css-loader/-/css-loader-7.1.1.tgz",
|
||||
"integrity": "sha512-OxIR5P2mjO1PSXk44bWuQ8XtMK4dpEqpIyERCx3ewOo3I8EmbcxMPUc5ScLtQfgXtOojoMv57So4V/C02HQLsw==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"icss-utils": "^5.1.0",
|
||||
|
@ -1477,7 +1477,7 @@
|
|||
"semver": "^7.5.4"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 12.13.0"
|
||||
"node": ">= 18.12.0"
|
||||
},
|
||||
"funding": {
|
||||
"type": "opencollective",
|
||||
|
@ -1485,7 +1485,7 @@
|
|||
},
|
||||
"peerDependencies": {
|
||||
"@rspack/core": "0.x || 1.x",
|
||||
"webpack": "^5.0.0"
|
||||
"webpack": "^5.27.0"
|
||||
},
|
||||
"peerDependenciesMeta": {
|
||||
"@rspack/core": {
|
||||
|
@ -1602,9 +1602,9 @@
|
|||
"integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA=="
|
||||
},
|
||||
"node_modules/electron-to-chromium": {
|
||||
"version": "1.4.756",
|
||||
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.756.tgz",
|
||||
"integrity": "sha512-RJKZ9+vEBMeiPAvKNWyZjuYyUqMndcP1f335oHqn3BEQbs2NFtVrnK5+6Xg5wSM9TknNNpWghGDUCKGYF+xWXw=="
|
||||
"version": "1.4.769",
|
||||
"resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.769.tgz",
|
||||
"integrity": "sha512-bZu7p623NEA2rHTc9K1vykl57ektSPQYFFqQir8BOYf6EKOB+yIsbFB9Kpm7Cgt6tsLr9sRkqfqSZUw7LP1XxQ=="
|
||||
},
|
||||
"node_modules/emoji-regex": {
|
||||
"version": "10.3.0",
|
||||
|
@ -1621,9 +1621,9 @@
|
|||
}
|
||||
},
|
||||
"node_modules/enhanced-resolve": {
|
||||
"version": "5.16.0",
|
||||
"resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.16.0.tgz",
|
||||
"integrity": "sha512-O+QWCviPNSSLAD9Ucn8Awv+poAkqn3T1XY5/N7kR7rQO9yfSGWkYZDwpJ+iKF7B8rxaQKWngSqACpgzeapSyoA==",
|
||||
"version": "5.16.1",
|
||||
"resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.16.1.tgz",
|
||||
"integrity": "sha512-4U5pNsuDl0EhuZpq46M5xPslstkviJuhrdobaRDBk2Jy2KO37FDAJl4lb2KlNabxT0m4MTK2UHNrsAcphE8nyw==",
|
||||
"peer": true,
|
||||
"dependencies": {
|
||||
"graceful-fs": "^4.2.4",
|
||||
|
@ -1981,21 +1981,21 @@
|
|||
}
|
||||
},
|
||||
"node_modules/glob": {
|
||||
"version": "10.3.12",
|
||||
"resolved": "https://registry.npmjs.org/glob/-/glob-10.3.12.tgz",
|
||||
"integrity": "sha512-TCNv8vJ+xz4QiqTpfOJA7HvYv+tNIRHKfUWw/q+v2jdgN4ebz+KY9tGx5J4rHP0o84mNP+ApH66HRX8us3Khqg==",
|
||||
"version": "10.3.15",
|
||||
"resolved": "https://registry.npmjs.org/glob/-/glob-10.3.15.tgz",
|
||||
"integrity": "sha512-0c6RlJt1TICLyvJYIApxb8GsXoai0KUP7AxKKAtsYXdgJR1mGEUa7DgwShbdk1nly0PYoZj01xd4hzbq3fsjpw==",
|
||||
"dependencies": {
|
||||
"foreground-child": "^3.1.0",
|
||||
"jackspeak": "^2.3.6",
|
||||
"minimatch": "^9.0.1",
|
||||
"minipass": "^7.0.4",
|
||||
"path-scurry": "^1.10.2"
|
||||
"path-scurry": "^1.11.0"
|
||||
},
|
||||
"bin": {
|
||||
"glob": "dist/esm/bin.mjs"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=16 || 14 >=14.17"
|
||||
"node": ">=16 || 14 >=14.18"
|
||||
},
|
||||
"funding": {
|
||||
"url": "https://github.com/sponsors/isaacs"
|
||||
|
@ -2438,15 +2438,11 @@
|
|||
}
|
||||
},
|
||||
"node_modules/lru-cache": {
|
||||
"version": "6.0.0",
|
||||
"resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz",
|
||||
"integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"yallist": "^4.0.0"
|
||||
},
|
||||
"version": "10.2.2",
|
||||
"resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.2.2.tgz",
|
||||
"integrity": "sha512-9hp3Vp2/hFQUiIwKo8XCeFVnrg8Pk3TYNPIR7tJADKi5YfcF7vEaK7avFHTlSy3kOKYaJQaalfEo6YuXdceBOQ==",
|
||||
"engines": {
|
||||
"node": ">=10"
|
||||
"node": "14 || >=16.14"
|
||||
}
|
||||
},
|
||||
"node_modules/magic-string": {
|
||||
|
@ -2536,9 +2532,9 @@
|
|||
}
|
||||
},
|
||||
"node_modules/minipass": {
|
||||
"version": "7.1.0",
|
||||
"resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.0.tgz",
|
||||
"integrity": "sha512-oGZRv2OT1lO2UF1zUcwdTb3wqUwI0kBGTgt/T7OdSj6M6N5m3o5uPf0AIW6lVxGGoiWUR7e2AwTE+xiwK8WQig==",
|
||||
"version": "7.1.1",
|
||||
"resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.1.tgz",
|
||||
"integrity": "sha512-UZ7eQ+h8ywIRAW1hIEl2AqdwzJucU/Kp59+8kkZeSvafXhZjul247BvIJjEVFVeON6d7lM46XX1HXCduKAS8VA==",
|
||||
"engines": {
|
||||
"node": ">=16 || 14 >=14.17"
|
||||
}
|
||||
|
@ -2688,32 +2684,24 @@
|
|||
"integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw=="
|
||||
},
|
||||
"node_modules/path-scurry": {
|
||||
"version": "1.10.2",
|
||||
"resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.10.2.tgz",
|
||||
"integrity": "sha512-7xTavNy5RQXnsjANvVvMkEjvloOinkAjv/Z6Ildz9v2RinZ4SBKTWFOVRbaF8p0vpHnyjV/UwNDdKuUv6M5qcA==",
|
||||
"version": "1.11.1",
|
||||
"resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.11.1.tgz",
|
||||
"integrity": "sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==",
|
||||
"dependencies": {
|
||||
"lru-cache": "^10.2.0",
|
||||
"minipass": "^5.0.0 || ^6.0.2 || ^7.0.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=16 || 14 >=14.17"
|
||||
"node": ">=16 || 14 >=14.18"
|
||||
},
|
||||
"funding": {
|
||||
"url": "https://github.com/sponsors/isaacs"
|
||||
}
|
||||
},
|
||||
"node_modules/path-scurry/node_modules/lru-cache": {
|
||||
"version": "10.2.2",
|
||||
"resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.2.2.tgz",
|
||||
"integrity": "sha512-9hp3Vp2/hFQUiIwKo8XCeFVnrg8Pk3TYNPIR7tJADKi5YfcF7vEaK7avFHTlSy3kOKYaJQaalfEo6YuXdceBOQ==",
|
||||
"engines": {
|
||||
"node": "14 || >=16.14"
|
||||
}
|
||||
},
|
||||
"node_modules/picocolors": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz",
|
||||
"integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ=="
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.1.tgz",
|
||||
"integrity": "sha512-anP1Z8qwhkbmu7MFP5iTt+wQKXgwzf7zTyGlcdzabySa9vd0Xt392U0rVmz9poOaBj0uHJKyyo9/upk0HrEQew=="
|
||||
},
|
||||
"node_modules/picomatch": {
|
||||
"version": "2.3.1",
|
||||
|
@ -3216,13 +3204,10 @@
|
|||
}
|
||||
},
|
||||
"node_modules/semver": {
|
||||
"version": "7.6.0",
|
||||
"resolved": "https://registry.npmjs.org/semver/-/semver-7.6.0.tgz",
|
||||
"integrity": "sha512-EnwXhrlwXMk9gKu5/flx5sv/an57AkRplG3hTK68W7FRDN+k+OWBj65M7719OkA82XLBxrcX0KSHj+X5COhOVg==",
|
||||
"version": "7.6.2",
|
||||
"resolved": "https://registry.npmjs.org/semver/-/semver-7.6.2.tgz",
|
||||
"integrity": "sha512-FNAIBWCx9qcRhoHcgcJ0gvU7SN1lYU2ZXuSfl04bSC5OpvDHFyJCjdNHomPXxjQlCBU67YW64PzY7/VIEH7F2w==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"lru-cache": "^6.0.0"
|
||||
},
|
||||
"bin": {
|
||||
"semver": "bin/semver.js"
|
||||
},
|
||||
|
@ -3699,9 +3684,9 @@
|
|||
"peer": true
|
||||
},
|
||||
"node_modules/update-browserslist-db": {
|
||||
"version": "1.0.15",
|
||||
"resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.15.tgz",
|
||||
"integrity": "sha512-K9HWH62x3/EalU1U6sjSZiylm9C8tgq2mSvshZpqc7QE69RaA2qjhkW2HlNA0tFpEbtyFz7HTqbSdN4MSwUodA==",
|
||||
"version": "1.0.16",
|
||||
"resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.16.tgz",
|
||||
"integrity": "sha512-KVbTxlBYlckhF5wgfyZXTWnMn7MMZjMu9XG8bPlliUOP9ThaF4QnhP8qrjrH7DRzHfSk0oQv1wToW+iA5GajEQ==",
|
||||
"funding": [
|
||||
{
|
||||
"type": "opencollective",
|
||||
|
@ -3718,7 +3703,7 @@
|
|||
],
|
||||
"dependencies": {
|
||||
"escalade": "^3.1.2",
|
||||
"picocolors": "^1.0.0"
|
||||
"picocolors": "^1.0.1"
|
||||
},
|
||||
"bin": {
|
||||
"update-browserslist-db": "cli.js"
|
||||
|
@ -3807,15 +3792,15 @@
|
|||
}
|
||||
},
|
||||
"node_modules/vue": {
|
||||
"version": "3.4.26",
|
||||
"resolved": "https://registry.npmjs.org/vue/-/vue-3.4.26.tgz",
|
||||
"integrity": "sha512-bUIq/p+VB+0xrJubaemrfhk1/FiW9iX+pDV+62I/XJ6EkspAO9/DXEjbDFoe8pIfOZBqfk45i9BMc41ptP/uRg==",
|
||||
"version": "3.4.27",
|
||||
"resolved": "https://registry.npmjs.org/vue/-/vue-3.4.27.tgz",
|
||||
"integrity": "sha512-8s/56uK6r01r1icG/aEOHqyMVxd1bkYcSe9j8HcKtr/xTOFWvnzIVTehNW+5Yt89f+DLBe4A569pnZLS5HzAMA==",
|
||||
"dependencies": {
|
||||
"@vue/compiler-dom": "3.4.26",
|
||||
"@vue/compiler-sfc": "3.4.26",
|
||||
"@vue/runtime-dom": "3.4.26",
|
||||
"@vue/server-renderer": "3.4.26",
|
||||
"@vue/shared": "3.4.26"
|
||||
"@vue/compiler-dom": "3.4.27",
|
||||
"@vue/compiler-sfc": "3.4.27",
|
||||
"@vue/runtime-dom": "3.4.27",
|
||||
"@vue/server-renderer": "3.4.27",
|
||||
"@vue/shared": "3.4.27"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"typescript": "*"
|
||||
|
@ -4100,12 +4085,6 @@
|
|||
"node": ">=8"
|
||||
}
|
||||
},
|
||||
"node_modules/yallist": {
|
||||
"version": "4.0.0",
|
||||
"resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz",
|
||||
"integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==",
|
||||
"dev": true
|
||||
},
|
||||
"node_modules/yaml": {
|
||||
"version": "2.3.4",
|
||||
"resolved": "https://registry.npmjs.org/yaml/-/yaml-2.3.4.tgz",
|
||||
|
|
|
@ -35,7 +35,7 @@
|
|||
},
|
||||
"devDependencies": {
|
||||
"@vitejs/plugin-vue": "^5.0.0",
|
||||
"css-loader": "^6.0.0",
|
||||
"css-loader": "^7.0.0",
|
||||
"husky": "^9.0.0",
|
||||
"laravel-vite-plugin": "^1.0.0",
|
||||
"lint-staged": "^15.0.0",
|
||||
|
|
|
@ -234,7 +234,7 @@ try {
|
|||
sendAction(getAction($domainActionQuery));
|
||||
}
|
||||
}
|
||||
} catch (\Exception $e) {
|
||||
} catch (\Throwable $e) {
|
||||
logData($e->getMessage());
|
||||
|
||||
exit(0);
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"require": {
|
||||
"illuminate/database": "^10.0",
|
||||
"illuminate/database": "^11.0",
|
||||
"vlucas/phpdotenv": "^5.5",
|
||||
"paragonie/constant_time_encoding": "^2.6"
|
||||
"paragonie/constant_time_encoding": "^3.0"
|
||||
}
|
||||
}
|
||||
|
|
400
postfix/composer.lock
generated
400
postfix/composer.lock
generated
|
@ -4,7 +4,7 @@
|
|||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"content-hash": "46d9d11a3c6417de4c53dbd5441cef7a",
|
||||
"content-hash": "512b6f9ace84603f8d22b04432fc6cfc",
|
||||
"packages": [
|
||||
{
|
||||
"name": "brick/math",
|
||||
|
@ -68,26 +68,26 @@
|
|||
},
|
||||
{
|
||||
"name": "carbonphp/carbon-doctrine-types",
|
||||
"version": "2.1.0",
|
||||
"version": "3.2.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/CarbonPHP/carbon-doctrine-types.git",
|
||||
"reference": "99f76ffa36cce3b70a4a6abce41dba15ca2e84cb"
|
||||
"reference": "18ba5ddfec8976260ead6e866180bd5d2f71aa1d"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/CarbonPHP/carbon-doctrine-types/zipball/99f76ffa36cce3b70a4a6abce41dba15ca2e84cb",
|
||||
"reference": "99f76ffa36cce3b70a4a6abce41dba15ca2e84cb",
|
||||
"url": "https://api.github.com/repos/CarbonPHP/carbon-doctrine-types/zipball/18ba5ddfec8976260ead6e866180bd5d2f71aa1d",
|
||||
"reference": "18ba5ddfec8976260ead6e866180bd5d2f71aa1d",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^7.4 || ^8.0"
|
||||
"php": "^8.1"
|
||||
},
|
||||
"conflict": {
|
||||
"doctrine/dbal": "<3.7.0 || >=4.0.0"
|
||||
"doctrine/dbal": "<4.0.0 || >=5.0.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"doctrine/dbal": "^3.7.0",
|
||||
"doctrine/dbal": "^4.0.0",
|
||||
"nesbot/carbon": "^2.71.0 || ^3.0.0",
|
||||
"phpunit/phpunit": "^10.3"
|
||||
},
|
||||
|
@ -117,7 +117,7 @@
|
|||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/CarbonPHP/carbon-doctrine-types/issues",
|
||||
"source": "https://github.com/CarbonPHP/carbon-doctrine-types/tree/2.1.0"
|
||||
"source": "https://github.com/CarbonPHP/carbon-doctrine-types/tree/3.2.0"
|
||||
},
|
||||
"funding": [
|
||||
{
|
||||
|
@ -133,7 +133,7 @@
|
|||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2023-12-11T17:09:12+00:00"
|
||||
"time": "2024-02-09T16:56:22+00:00"
|
||||
},
|
||||
{
|
||||
"name": "doctrine/inflector",
|
||||
|
@ -290,31 +290,31 @@
|
|||
},
|
||||
{
|
||||
"name": "illuminate/collections",
|
||||
"version": "v10.48.10",
|
||||
"version": "v11.7.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/illuminate/collections.git",
|
||||
"reference": "f9589f1063a449111dcaa1d68285b507d9483a95"
|
||||
"reference": "3859367b55d977bcf5da86680c787dffaaacdb86"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/illuminate/collections/zipball/f9589f1063a449111dcaa1d68285b507d9483a95",
|
||||
"reference": "f9589f1063a449111dcaa1d68285b507d9483a95",
|
||||
"url": "https://api.github.com/repos/illuminate/collections/zipball/3859367b55d977bcf5da86680c787dffaaacdb86",
|
||||
"reference": "3859367b55d977bcf5da86680c787dffaaacdb86",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"illuminate/conditionable": "^10.0",
|
||||
"illuminate/contracts": "^10.0",
|
||||
"illuminate/macroable": "^10.0",
|
||||
"php": "^8.1"
|
||||
"illuminate/conditionable": "^11.0",
|
||||
"illuminate/contracts": "^11.0",
|
||||
"illuminate/macroable": "^11.0",
|
||||
"php": "^8.2"
|
||||
},
|
||||
"suggest": {
|
||||
"symfony/var-dumper": "Required to use the dump method (^6.2)."
|
||||
"symfony/var-dumper": "Required to use the dump method (^7.0)."
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "10.x-dev"
|
||||
"dev-master": "11.x-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
|
@ -341,20 +341,20 @@
|
|||
"issues": "https://github.com/laravel/framework/issues",
|
||||
"source": "https://github.com/laravel/framework"
|
||||
},
|
||||
"time": "2024-03-20T20:09:13+00:00"
|
||||
"time": "2024-05-05T15:36:09+00:00"
|
||||
},
|
||||
{
|
||||
"name": "illuminate/conditionable",
|
||||
"version": "v10.48.10",
|
||||
"version": "v11.7.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/illuminate/conditionable.git",
|
||||
"reference": "d0958e4741fc9d6f516a552060fd1b829a85e009"
|
||||
"reference": "8a558fec063b6a63da1c3af1d219c0f998edffeb"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/illuminate/conditionable/zipball/d0958e4741fc9d6f516a552060fd1b829a85e009",
|
||||
"reference": "d0958e4741fc9d6f516a552060fd1b829a85e009",
|
||||
"url": "https://api.github.com/repos/illuminate/conditionable/zipball/8a558fec063b6a63da1c3af1d219c0f998edffeb",
|
||||
"reference": "8a558fec063b6a63da1c3af1d219c0f998edffeb",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
|
@ -363,7 +363,7 @@
|
|||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "10.x-dev"
|
||||
"dev-master": "11.x-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
|
@ -387,25 +387,25 @@
|
|||
"issues": "https://github.com/laravel/framework/issues",
|
||||
"source": "https://github.com/laravel/framework"
|
||||
},
|
||||
"time": "2023-02-03T08:06:17+00:00"
|
||||
"time": "2024-04-04T17:36:49+00:00"
|
||||
},
|
||||
{
|
||||
"name": "illuminate/container",
|
||||
"version": "v10.48.10",
|
||||
"version": "v11.7.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/illuminate/container.git",
|
||||
"reference": "ddc26273085fad3c471b2602ad820e0097ff7939"
|
||||
"reference": "af979ecfd6dfa6583eae5dfe2e9a8840358f4ca7"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/illuminate/container/zipball/ddc26273085fad3c471b2602ad820e0097ff7939",
|
||||
"reference": "ddc26273085fad3c471b2602ad820e0097ff7939",
|
||||
"url": "https://api.github.com/repos/illuminate/container/zipball/af979ecfd6dfa6583eae5dfe2e9a8840358f4ca7",
|
||||
"reference": "af979ecfd6dfa6583eae5dfe2e9a8840358f4ca7",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"illuminate/contracts": "^10.0",
|
||||
"php": "^8.1",
|
||||
"illuminate/contracts": "^11.0",
|
||||
"php": "^8.2",
|
||||
"psr/container": "^1.1.1|^2.0.1"
|
||||
},
|
||||
"provide": {
|
||||
|
@ -414,7 +414,7 @@
|
|||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "10.x-dev"
|
||||
"dev-master": "11.x-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
|
@ -438,31 +438,31 @@
|
|||
"issues": "https://github.com/laravel/framework/issues",
|
||||
"source": "https://github.com/laravel/framework"
|
||||
},
|
||||
"time": "2023-06-18T09:12:03+00:00"
|
||||
"time": "2024-04-04T17:36:49+00:00"
|
||||
},
|
||||
{
|
||||
"name": "illuminate/contracts",
|
||||
"version": "v10.48.10",
|
||||
"version": "v11.7.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/illuminate/contracts.git",
|
||||
"reference": "8d7152c4a1f5d9cf7da3e8b71f23e4556f6138ac"
|
||||
"reference": "8782f75e80ab3e6036842d24dbeead34a16f3a79"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/illuminate/contracts/zipball/8d7152c4a1f5d9cf7da3e8b71f23e4556f6138ac",
|
||||
"reference": "8d7152c4a1f5d9cf7da3e8b71f23e4556f6138ac",
|
||||
"url": "https://api.github.com/repos/illuminate/contracts/zipball/8782f75e80ab3e6036842d24dbeead34a16f3a79",
|
||||
"reference": "8782f75e80ab3e6036842d24dbeead34a16f3a79",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^8.1",
|
||||
"php": "^8.2",
|
||||
"psr/container": "^1.1.1|^2.0.1",
|
||||
"psr/simple-cache": "^1.0|^2.0|^3.0"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "10.x-dev"
|
||||
"dev-master": "11.x-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
|
@ -486,50 +486,45 @@
|
|||
"issues": "https://github.com/laravel/framework/issues",
|
||||
"source": "https://github.com/laravel/framework"
|
||||
},
|
||||
"time": "2024-01-15T18:52:32+00:00"
|
||||
"time": "2024-04-17T14:09:55+00:00"
|
||||
},
|
||||
{
|
||||
"name": "illuminate/database",
|
||||
"version": "v10.48.10",
|
||||
"version": "v11.7.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/illuminate/database.git",
|
||||
"reference": "eb8edf206d3a6eea8894bc6e21f53469e27dd5c9"
|
||||
"reference": "49a2dd6fba0cfa0d3a11fd15433059f7f5fba45a"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/illuminate/database/zipball/eb8edf206d3a6eea8894bc6e21f53469e27dd5c9",
|
||||
"reference": "eb8edf206d3a6eea8894bc6e21f53469e27dd5c9",
|
||||
"url": "https://api.github.com/repos/illuminate/database/zipball/49a2dd6fba0cfa0d3a11fd15433059f7f5fba45a",
|
||||
"reference": "49a2dd6fba0cfa0d3a11fd15433059f7f5fba45a",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"brick/math": "^0.9.3|^0.10.2|^0.11|^0.12",
|
||||
"ext-pdo": "*",
|
||||
"illuminate/collections": "^10.0",
|
||||
"illuminate/container": "^10.0",
|
||||
"illuminate/contracts": "^10.0",
|
||||
"illuminate/macroable": "^10.0",
|
||||
"illuminate/support": "^10.0",
|
||||
"php": "^8.1"
|
||||
},
|
||||
"conflict": {
|
||||
"carbonphp/carbon-doctrine-types": ">=3.0",
|
||||
"doctrine/dbal": ">=4.0"
|
||||
"illuminate/collections": "^11.0",
|
||||
"illuminate/container": "^11.0",
|
||||
"illuminate/contracts": "^11.0",
|
||||
"illuminate/macroable": "^11.0",
|
||||
"illuminate/support": "^11.0",
|
||||
"php": "^8.2"
|
||||
},
|
||||
"suggest": {
|
||||
"doctrine/dbal": "Required to rename columns and drop SQLite columns (^3.5.1).",
|
||||
"ext-filter": "Required to use the Postgres database driver.",
|
||||
"fakerphp/faker": "Required to use the eloquent factory builder (^1.21).",
|
||||
"illuminate/console": "Required to use the database commands (^10.0).",
|
||||
"illuminate/events": "Required to use the observers with Eloquent (^10.0).",
|
||||
"illuminate/filesystem": "Required to use the migrations (^10.0).",
|
||||
"illuminate/pagination": "Required to paginate the result set (^10.0).",
|
||||
"symfony/finder": "Required to use Eloquent model factories (^6.2)."
|
||||
"illuminate/console": "Required to use the database commands (^11.0).",
|
||||
"illuminate/events": "Required to use the observers with Eloquent (^11.0).",
|
||||
"illuminate/filesystem": "Required to use the migrations (^11.0).",
|
||||
"illuminate/pagination": "Required to paginate the result set (^11.0).",
|
||||
"symfony/finder": "Required to use Eloquent model factories (^7.0)."
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "10.x-dev"
|
||||
"dev-master": "11.x-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
|
@ -559,29 +554,29 @@
|
|||
"issues": "https://github.com/laravel/framework/issues",
|
||||
"source": "https://github.com/laravel/framework"
|
||||
},
|
||||
"time": "2024-04-29T13:23:17+00:00"
|
||||
"time": "2024-05-06T18:08:11+00:00"
|
||||
},
|
||||
{
|
||||
"name": "illuminate/macroable",
|
||||
"version": "v10.48.10",
|
||||
"version": "v11.7.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/illuminate/macroable.git",
|
||||
"reference": "dff667a46ac37b634dcf68909d9d41e94dc97c27"
|
||||
"reference": "e1be58f9b2af73f242dc6a9add1f376b3ec89eef"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/illuminate/macroable/zipball/dff667a46ac37b634dcf68909d9d41e94dc97c27",
|
||||
"reference": "dff667a46ac37b634dcf68909d9d41e94dc97c27",
|
||||
"url": "https://api.github.com/repos/illuminate/macroable/zipball/e1be58f9b2af73f242dc6a9add1f376b3ec89eef",
|
||||
"reference": "e1be58f9b2af73f242dc6a9add1f376b3ec89eef",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^8.1"
|
||||
"php": "^8.2"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "10.x-dev"
|
||||
"dev-master": "11.x-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
|
@ -605,20 +600,20 @@
|
|||
"issues": "https://github.com/laravel/framework/issues",
|
||||
"source": "https://github.com/laravel/framework"
|
||||
},
|
||||
"time": "2023-06-05T12:46:42+00:00"
|
||||
"time": "2023-06-08T14:08:27+00:00"
|
||||
},
|
||||
{
|
||||
"name": "illuminate/support",
|
||||
"version": "v10.48.10",
|
||||
"version": "v11.7.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/illuminate/support.git",
|
||||
"reference": "ee3a1aaed36d916654ce0ae09dfbd38644a4f582"
|
||||
"reference": "7d733a1dbeb96557ba287e778bbf7bc61e23c31d"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/illuminate/support/zipball/ee3a1aaed36d916654ce0ae09dfbd38644a4f582",
|
||||
"reference": "ee3a1aaed36d916654ce0ae09dfbd38644a4f582",
|
||||
"url": "https://api.github.com/repos/illuminate/support/zipball/7d733a1dbeb96557ba287e778bbf7bc61e23c31d",
|
||||
"reference": "7d733a1dbeb96557ba287e778bbf7bc61e23c31d",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
|
@ -626,30 +621,33 @@
|
|||
"ext-ctype": "*",
|
||||
"ext-filter": "*",
|
||||
"ext-mbstring": "*",
|
||||
"illuminate/collections": "^10.0",
|
||||
"illuminate/conditionable": "^10.0",
|
||||
"illuminate/contracts": "^10.0",
|
||||
"illuminate/macroable": "^10.0",
|
||||
"nesbot/carbon": "^2.67",
|
||||
"php": "^8.1",
|
||||
"illuminate/collections": "^11.0",
|
||||
"illuminate/conditionable": "^11.0",
|
||||
"illuminate/contracts": "^11.0",
|
||||
"illuminate/macroable": "^11.0",
|
||||
"nesbot/carbon": "^2.72.2|^3.0",
|
||||
"php": "^8.2",
|
||||
"voku/portable-ascii": "^2.0"
|
||||
},
|
||||
"conflict": {
|
||||
"tightenco/collect": "<5.5.33"
|
||||
},
|
||||
"replace": {
|
||||
"spatie/once": "*"
|
||||
},
|
||||
"suggest": {
|
||||
"illuminate/filesystem": "Required to use the composer class (^10.0).",
|
||||
"illuminate/filesystem": "Required to use the composer class (^11.0).",
|
||||
"league/commonmark": "Required to use Str::markdown() and Stringable::markdown() (^2.0.2).",
|
||||
"ramsey/uuid": "Required to use Str::uuid() (^4.7).",
|
||||
"symfony/process": "Required to use the composer class (^6.2).",
|
||||
"symfony/uid": "Required to use Str::ulid() (^6.2).",
|
||||
"symfony/var-dumper": "Required to use the dd function (^6.2).",
|
||||
"symfony/process": "Required to use the composer class (^7.0).",
|
||||
"symfony/uid": "Required to use Str::ulid() (^7.0).",
|
||||
"symfony/var-dumper": "Required to use the dd function (^7.0).",
|
||||
"vlucas/phpdotenv": "Required to use the Env class and env helper (^5.4.1)."
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "10.x-dev"
|
||||
"dev-master": "11.x-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
|
@ -676,46 +674,45 @@
|
|||
"issues": "https://github.com/laravel/framework/issues",
|
||||
"source": "https://github.com/laravel/framework"
|
||||
},
|
||||
"time": "2024-04-07T17:47:33+00:00"
|
||||
"time": "2024-05-06T18:30:15+00:00"
|
||||
},
|
||||
{
|
||||
"name": "nesbot/carbon",
|
||||
"version": "2.72.3",
|
||||
"version": "3.3.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/briannesbitt/Carbon.git",
|
||||
"reference": "0c6fd108360c562f6e4fd1dedb8233b423e91c83"
|
||||
"reference": "8ff64b92c1b1ec84fcde9f8bb9ff2ca34cb8a77a"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/0c6fd108360c562f6e4fd1dedb8233b423e91c83",
|
||||
"reference": "0c6fd108360c562f6e4fd1dedb8233b423e91c83",
|
||||
"url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/8ff64b92c1b1ec84fcde9f8bb9ff2ca34cb8a77a",
|
||||
"reference": "8ff64b92c1b1ec84fcde9f8bb9ff2ca34cb8a77a",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"carbonphp/carbon-doctrine-types": "*",
|
||||
"ext-json": "*",
|
||||
"php": "^7.1.8 || ^8.0",
|
||||
"php": "^8.1",
|
||||
"psr/clock": "^1.0",
|
||||
"symfony/clock": "^6.3 || ^7.0",
|
||||
"symfony/polyfill-mbstring": "^1.0",
|
||||
"symfony/polyfill-php80": "^1.16",
|
||||
"symfony/translation": "^3.4 || ^4.0 || ^5.0 || ^6.0"
|
||||
"symfony/translation": "^4.4.18 || ^5.2.1|| ^6.0 || ^7.0"
|
||||
},
|
||||
"provide": {
|
||||
"psr/clock-implementation": "1.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"doctrine/dbal": "^2.0 || ^3.1.4 || ^4.0",
|
||||
"doctrine/orm": "^2.7 || ^3.0",
|
||||
"friendsofphp/php-cs-fixer": "^3.0",
|
||||
"kylekatarnls/multi-tester": "^2.0",
|
||||
"ondrejmirtes/better-reflection": "*",
|
||||
"phpmd/phpmd": "^2.9",
|
||||
"phpstan/extension-installer": "^1.0",
|
||||
"phpstan/phpstan": "^0.12.99 || ^1.7.14",
|
||||
"phpunit/php-file-iterator": "^2.0.5 || ^3.0.6",
|
||||
"phpunit/phpunit": "^7.5.20 || ^8.5.26 || ^9.5.20",
|
||||
"squizlabs/php_codesniffer": "^3.4"
|
||||
"doctrine/dbal": "^3.6.3 || ^4.0",
|
||||
"doctrine/orm": "^2.15.2 || ^3.0",
|
||||
"friendsofphp/php-cs-fixer": "^3.52.1",
|
||||
"kylekatarnls/multi-tester": "^2.5.3",
|
||||
"ondrejmirtes/better-reflection": "^6.25.0.4",
|
||||
"phpmd/phpmd": "^2.15.0",
|
||||
"phpstan/extension-installer": "^1.3.1",
|
||||
"phpstan/phpstan": "^1.10.65",
|
||||
"phpunit/phpunit": "^10.5.15",
|
||||
"squizlabs/php_codesniffer": "^3.9.0"
|
||||
},
|
||||
"bin": [
|
||||
"bin/carbon"
|
||||
|
@ -723,8 +720,8 @@
|
|||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-3.x": "3.x-dev",
|
||||
"dev-master": "2.x-dev"
|
||||
"dev-master": "3.x-dev",
|
||||
"dev-2.x": "2.x-dev"
|
||||
},
|
||||
"laravel": {
|
||||
"providers": [
|
||||
|
@ -783,28 +780,28 @@
|
|||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2024-01-25T10:35:09+00:00"
|
||||
"time": "2024-05-01T06:54:22+00:00"
|
||||
},
|
||||
{
|
||||
"name": "paragonie/constant_time_encoding",
|
||||
"version": "v2.6.3",
|
||||
"version": "v3.0.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/paragonie/constant_time_encoding.git",
|
||||
"reference": "58c3f47f650c94ec05a151692652a868995d2938"
|
||||
"reference": "df1e7fde177501eee2037dd159cf04f5f301a512"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/paragonie/constant_time_encoding/zipball/58c3f47f650c94ec05a151692652a868995d2938",
|
||||
"reference": "58c3f47f650c94ec05a151692652a868995d2938",
|
||||
"url": "https://api.github.com/repos/paragonie/constant_time_encoding/zipball/df1e7fde177501eee2037dd159cf04f5f301a512",
|
||||
"reference": "df1e7fde177501eee2037dd159cf04f5f301a512",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^7|^8"
|
||||
"php": "^8"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "^6|^7|^8|^9",
|
||||
"vimeo/psalm": "^1|^2|^3|^4"
|
||||
"phpunit/phpunit": "^9",
|
||||
"vimeo/psalm": "^4|^5"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
|
@ -850,7 +847,7 @@
|
|||
"issues": "https://github.com/paragonie/constant_time_encoding/issues",
|
||||
"source": "https://github.com/paragonie/constant_time_encoding"
|
||||
},
|
||||
"time": "2022-06-14T06:56:20+00:00"
|
||||
"time": "2024-05-08T12:36:18+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpoption/phpoption",
|
||||
|
@ -1080,35 +1077,37 @@
|
|||
"time": "2021-10-29T13:26:27+00:00"
|
||||
},
|
||||
{
|
||||
"name": "symfony/deprecation-contracts",
|
||||
"version": "v3.5.0",
|
||||
"name": "symfony/clock",
|
||||
"version": "v7.0.7",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/deprecation-contracts.git",
|
||||
"reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1"
|
||||
"url": "https://github.com/symfony/clock.git",
|
||||
"reference": "2008671acb4a30b01c453de193cf9c80549ebda6"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1",
|
||||
"reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1",
|
||||
"url": "https://api.github.com/repos/symfony/clock/zipball/2008671acb4a30b01c453de193cf9c80549ebda6",
|
||||
"reference": "2008671acb4a30b01c453de193cf9c80549ebda6",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=8.1"
|
||||
"php": ">=8.2",
|
||||
"psr/clock": "^1.0",
|
||||
"symfony/polyfill-php83": "^1.28"
|
||||
},
|
||||
"provide": {
|
||||
"psr/clock-implementation": "1.0"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-main": "3.5-dev"
|
||||
},
|
||||
"thanks": {
|
||||
"name": "symfony/contracts",
|
||||
"url": "https://github.com/symfony/contracts"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"files": [
|
||||
"function.php"
|
||||
"Resources/now.php"
|
||||
],
|
||||
"psr-4": {
|
||||
"Symfony\\Component\\Clock\\": ""
|
||||
},
|
||||
"exclude-from-classmap": [
|
||||
"/Tests/"
|
||||
]
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
|
@ -1125,10 +1124,15 @@
|
|||
"homepage": "https://symfony.com/contributors"
|
||||
}
|
||||
],
|
||||
"description": "A generic function and convention to trigger deprecation notices",
|
||||
"description": "Decouples applications from the system clock",
|
||||
"homepage": "https://symfony.com",
|
||||
"keywords": [
|
||||
"clock",
|
||||
"psr20",
|
||||
"time"
|
||||
],
|
||||
"support": {
|
||||
"source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.0"
|
||||
"source": "https://github.com/symfony/clock/tree/v7.0.7"
|
||||
},
|
||||
"funding": [
|
||||
{
|
||||
|
@ -1144,7 +1148,7 @@
|
|||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2024-04-18T09:32:20+00:00"
|
||||
"time": "2024-04-18T09:29:19+00:00"
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-ctype",
|
||||
|
@ -1386,34 +1390,110 @@
|
|||
"time": "2024-01-29T20:11:03+00:00"
|
||||
},
|
||||
{
|
||||
"name": "symfony/translation",
|
||||
"version": "v6.4.7",
|
||||
"name": "symfony/polyfill-php83",
|
||||
"version": "v1.29.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/translation.git",
|
||||
"reference": "7495687c58bfd88b7883823747b0656d90679123"
|
||||
"url": "https://github.com/symfony/polyfill-php83.git",
|
||||
"reference": "86fcae159633351e5fd145d1c47de6c528f8caff"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/translation/zipball/7495687c58bfd88b7883823747b0656d90679123",
|
||||
"reference": "7495687c58bfd88b7883823747b0656d90679123",
|
||||
"url": "https://api.github.com/repos/symfony/polyfill-php83/zipball/86fcae159633351e5fd145d1c47de6c528f8caff",
|
||||
"reference": "86fcae159633351e5fd145d1c47de6c528f8caff",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=8.1",
|
||||
"symfony/deprecation-contracts": "^2.5|^3",
|
||||
"php": ">=7.1",
|
||||
"symfony/polyfill-php80": "^1.14"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"thanks": {
|
||||
"name": "symfony/polyfill",
|
||||
"url": "https://github.com/symfony/polyfill"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"files": [
|
||||
"bootstrap.php"
|
||||
],
|
||||
"psr-4": {
|
||||
"Symfony\\Polyfill\\Php83\\": ""
|
||||
},
|
||||
"classmap": [
|
||||
"Resources/stubs"
|
||||
]
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Nicolas Grekas",
|
||||
"email": "p@tchwork.com"
|
||||
},
|
||||
{
|
||||
"name": "Symfony Community",
|
||||
"homepage": "https://symfony.com/contributors"
|
||||
}
|
||||
],
|
||||
"description": "Symfony polyfill backporting some PHP 8.3+ features to lower PHP versions",
|
||||
"homepage": "https://symfony.com",
|
||||
"keywords": [
|
||||
"compatibility",
|
||||
"polyfill",
|
||||
"portable",
|
||||
"shim"
|
||||
],
|
||||
"support": {
|
||||
"source": "https://github.com/symfony/polyfill-php83/tree/v1.29.0"
|
||||
},
|
||||
"funding": [
|
||||
{
|
||||
"url": "https://symfony.com/sponsor",
|
||||
"type": "custom"
|
||||
},
|
||||
{
|
||||
"url": "https://github.com/fabpot",
|
||||
"type": "github"
|
||||
},
|
||||
{
|
||||
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
|
||||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2024-01-29T20:11:03+00:00"
|
||||
},
|
||||
{
|
||||
"name": "symfony/translation",
|
||||
"version": "v7.0.7",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/translation.git",
|
||||
"reference": "1515e03afaa93e6419aba5d5c9d209159317100b"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/translation/zipball/1515e03afaa93e6419aba5d5c9d209159317100b",
|
||||
"reference": "1515e03afaa93e6419aba5d5c9d209159317100b",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=8.2",
|
||||
"symfony/polyfill-mbstring": "~1.0",
|
||||
"symfony/translation-contracts": "^2.5|^3.0"
|
||||
},
|
||||
"conflict": {
|
||||
"symfony/config": "<5.4",
|
||||
"symfony/console": "<5.4",
|
||||
"symfony/dependency-injection": "<5.4",
|
||||
"symfony/config": "<6.4",
|
||||
"symfony/console": "<6.4",
|
||||
"symfony/dependency-injection": "<6.4",
|
||||
"symfony/http-client-contracts": "<2.5",
|
||||
"symfony/http-kernel": "<5.4",
|
||||
"symfony/http-kernel": "<6.4",
|
||||
"symfony/service-contracts": "<2.5",
|
||||
"symfony/twig-bundle": "<5.4",
|
||||
"symfony/yaml": "<5.4"
|
||||
"symfony/twig-bundle": "<6.4",
|
||||
"symfony/yaml": "<6.4"
|
||||
},
|
||||
"provide": {
|
||||
"symfony/translation-implementation": "2.3|3.0"
|
||||
|
@ -1421,17 +1501,17 @@
|
|||
"require-dev": {
|
||||
"nikic/php-parser": "^4.18|^5.0",
|
||||
"psr/log": "^1|^2|^3",
|
||||
"symfony/config": "^5.4|^6.0|^7.0",
|
||||
"symfony/console": "^5.4|^6.0|^7.0",
|
||||
"symfony/dependency-injection": "^5.4|^6.0|^7.0",
|
||||
"symfony/finder": "^5.4|^6.0|^7.0",
|
||||
"symfony/config": "^6.4|^7.0",
|
||||
"symfony/console": "^6.4|^7.0",
|
||||
"symfony/dependency-injection": "^6.4|^7.0",
|
||||
"symfony/finder": "^6.4|^7.0",
|
||||
"symfony/http-client-contracts": "^2.5|^3.0",
|
||||
"symfony/http-kernel": "^5.4|^6.0|^7.0",
|
||||
"symfony/intl": "^5.4|^6.0|^7.0",
|
||||
"symfony/http-kernel": "^6.4|^7.0",
|
||||
"symfony/intl": "^6.4|^7.0",
|
||||
"symfony/polyfill-intl-icu": "^1.21",
|
||||
"symfony/routing": "^5.4|^6.0|^7.0",
|
||||
"symfony/routing": "^6.4|^7.0",
|
||||
"symfony/service-contracts": "^2.5|^3",
|
||||
"symfony/yaml": "^5.4|^6.0|^7.0"
|
||||
"symfony/yaml": "^6.4|^7.0"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
|
@ -1462,7 +1542,7 @@
|
|||
"description": "Provides tools to internationalize your application",
|
||||
"homepage": "https://symfony.com",
|
||||
"support": {
|
||||
"source": "https://github.com/symfony/translation/tree/v6.4.7"
|
||||
"source": "https://github.com/symfony/translation/tree/v7.0.7"
|
||||
},
|
||||
"funding": [
|
||||
{
|
||||
|
@ -1478,7 +1558,7 @@
|
|||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2024-04-18T09:22:46+00:00"
|
||||
"time": "2024-04-18T09:29:19+00:00"
|
||||
},
|
||||
{
|
||||
"name": "symfony/translation-contracts",
|
||||
|
|
|
@ -1,55 +1,17 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Contracts\Http\Kernel;
|
||||
use Illuminate\Http\Request;
|
||||
|
||||
define('LARAVEL_START', microtime(true));
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Check If Application Is Under Maintenance
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| If the application is maintenance / demo mode via the "down" command we
|
||||
| will require this file so that any prerendered template can be shown
|
||||
| instead of starting the framework, which could cause an exception.
|
||||
|
|
||||
*/
|
||||
|
||||
if (file_exists(__DIR__.'/../storage/framework/maintenance.php')) {
|
||||
require __DIR__.'/../storage/framework/maintenance.php';
|
||||
// Determine if the application is in maintenance mode...
|
||||
if (file_exists($maintenance = __DIR__.'/../storage/framework/maintenance.php')) {
|
||||
require $maintenance;
|
||||
}
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Register The Auto Loader
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Composer provides a convenient, automatically generated class loader for
|
||||
| this application. We just need to utilize it! We'll simply require it
|
||||
| into the script here so we don't need to manually load our classes.
|
||||
|
|
||||
*/
|
||||
|
||||
// Register the Composer autoloader...
|
||||
require __DIR__.'/../vendor/autoload.php';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Run The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Once we have the application, we can handle the incoming request using
|
||||
| the application's HTTP kernel. Then, we will send the response back
|
||||
| to this client's browser, allowing them to enjoy our application.
|
||||
|
|
||||
*/
|
||||
|
||||
$app = require_once __DIR__.'/../bootstrap/app.php';
|
||||
|
||||
$kernel = $app->make(Kernel::class);
|
||||
|
||||
$response = tap($kernel->handle(
|
||||
$request = Request::capture()
|
||||
))->send();
|
||||
|
||||
$kernel->terminate($request, $response);
|
||||
// Bootstrap Laravel and handle the request...
|
||||
(require_once __DIR__.'/../bootstrap/app.php')
|
||||
->handleRequest(Request::capture());
|
||||
|
|
|
@ -773,14 +773,8 @@
|
|||
v-for="formatOption in aliasFormatOptions"
|
||||
:key="formatOption.value"
|
||||
:value="formatOption.value"
|
||||
:disabled="createAliasDomainIsShared && formatOption.value === 'custom'"
|
||||
>
|
||||
{{ formatOption.label }}
|
||||
{{
|
||||
createAliasDomainIsShared && formatOption.value === 'custom'
|
||||
? '(Not available for shared domains)'
|
||||
: ''
|
||||
}}
|
||||
</option>
|
||||
</select>
|
||||
</div>
|
||||
|
@ -1391,10 +1385,6 @@ const selectedAliasesToRestore = computed(() =>
|
|||
_.filter(selectedRows.value, row => row.deleted_at !== null),
|
||||
)
|
||||
|
||||
const createAliasDomainIsShared = computed(() =>
|
||||
props.sharedDomains.includes(createAliasDomain.value),
|
||||
)
|
||||
|
||||
const links = ref(props.initialRows.links.slice(1, -1))
|
||||
|
||||
const aliasIdToEdit = ref('')
|
||||
|
@ -1632,12 +1622,6 @@ watch(
|
|||
{ deep: true },
|
||||
)
|
||||
|
||||
watch(createAliasDomainIsShared, isShared => {
|
||||
if (isShared) {
|
||||
createAliasFormat.value = 'random_characters'
|
||||
}
|
||||
})
|
||||
|
||||
onMounted(() => {
|
||||
debounceToolips()
|
||||
})
|
||||
|
|
|
@ -957,7 +957,7 @@
|
|||
</template>
|
||||
|
||||
<script setup>
|
||||
import { useForm } from '@inertiajs/vue3'
|
||||
import { useForm, Link } from '@inertiajs/vue3'
|
||||
import SettingsLayout from './../../Layouts/SettingsLayout.vue'
|
||||
import { ExclamationCircleIcon } from '@heroicons/vue/20/solid'
|
||||
|
||||
|
|
|
@ -1,18 +0,0 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Support\Facades\Broadcast;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Broadcast Channels
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here you may register all of the event broadcasting channels that your
|
||||
| application supports. The given channel authorization callbacks are
|
||||
| used to check if an authenticated user can listen to the channel.
|
||||
|
|
||||
*/
|
||||
|
||||
Broadcast::channel('App.Models.User.{id}', function ($user, $id) {
|
||||
return (int) $user->id === (int) $id;
|
||||
});
|
|
@ -1,7 +1,6 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Foundation\Inspiring;
|
||||
use Illuminate\Support\Facades\Artisan;
|
||||
use Illuminate\Support\Facades\Schedule;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
|
@ -14,6 +13,12 @@ use Illuminate\Support\Facades\Artisan;
|
|||
|
|
||||
*/
|
||||
|
||||
Artisan::command('inspire', function () {
|
||||
$this->comment(Inspiring::quote());
|
||||
})->purpose('Display an inspiring quote');
|
||||
Schedule::command('anonaddy:reset-bandwidth')->monthlyOn(1, '00:00');
|
||||
Schedule::command('anonaddy:check-domains-sending-verification')->daily();
|
||||
Schedule::command('anonaddy:check-domains-mx-validation')->daily();
|
||||
Schedule::command('anonaddy:clear-failed-deliveries')->daily();
|
||||
Schedule::command('anonaddy:clear-outbound-messages')->everySixHours();
|
||||
Schedule::command('anonaddy:email-users-with-token-expiring-soon')->daily();
|
||||
Schedule::command('auth:clear-resets')->daily();
|
||||
Schedule::command('sanctum:prune-expired --hours=168')->daily();
|
||||
Schedule::command('cache:prune-stale-tags')->hourly();
|
||||
|
|
|
@ -1,22 +0,0 @@
|
|||
<?php
|
||||
|
||||
namespace Tests;
|
||||
|
||||
use Illuminate\Contracts\Console\Kernel;
|
||||
|
||||
trait CreatesApplication
|
||||
{
|
||||
/**
|
||||
* Creates the application.
|
||||
*
|
||||
* @return \Illuminate\Foundation\Application
|
||||
*/
|
||||
public function createApplication()
|
||||
{
|
||||
$app = require __DIR__.'/../bootstrap/app.php';
|
||||
|
||||
$app->make(Kernel::class)->bootstrap();
|
||||
|
||||
return $app;
|
||||
}
|
||||
}
|
|
@ -3,6 +3,7 @@
|
|||
namespace Tests\Feature\Api;
|
||||
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class AccountDetailsTest extends TestCase
|
||||
|
@ -15,7 +16,7 @@ class AccountDetailsTest extends TestCase
|
|||
parent::setUpSanctum();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_account_details()
|
||||
{
|
||||
$response = $this->json('GET', '/api/v1/account-details');
|
||||
|
|
|
@ -6,6 +6,7 @@ use App\Models\Alias;
|
|||
use App\Models\AliasRecipient;
|
||||
use App\Models\Recipient;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class AliasRecipientsTest extends TestCase
|
||||
|
@ -18,7 +19,7 @@ class AliasRecipientsTest extends TestCase
|
|||
parent::setUpSanctum();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_attach_recipient_to_alias()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -39,7 +40,7 @@ class AliasRecipientsTest extends TestCase
|
|||
$this->assertEquals($recipient->email, $alias->recipients[0]->email);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_attach_multiple_recipients_to_alias()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -67,7 +68,7 @@ class AliasRecipientsTest extends TestCase
|
|||
$this->assertCount(3, $alias->recipients);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_existing_recipients_for_alias()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -100,7 +101,7 @@ class AliasRecipientsTest extends TestCase
|
|||
$this->assertCount(2, $alias->recipients);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_attach_unverified_recipient_to_alias()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -121,7 +122,7 @@ class AliasRecipientsTest extends TestCase
|
|||
$this->assertCount(0, $alias->recipients);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_attach_more_than_allowed_recipients_to_alias()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -141,7 +142,7 @@ class AliasRecipientsTest extends TestCase
|
|||
$this->assertCount(0, $alias->recipients);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function alias_recipient_record_is_deleted_if_recipient_is_deleted()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
|
|
@ -7,6 +7,7 @@ use App\Models\Domain;
|
|||
use App\Models\Recipient;
|
||||
use App\Models\Username;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class AliasesTest extends TestCase
|
||||
|
@ -22,7 +23,7 @@ class AliasesTest extends TestCase
|
|||
$this->user->defaultUsername->save();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_all_aliases()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -38,7 +39,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertCount(3, $response->json()['data']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_all_aliases_including_deleted()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -59,7 +60,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertCount(3, $response->json()['data']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_only_deleted_aliases()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -80,7 +81,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertCount(2, $response->json()['data']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_only_active_aliases()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -102,7 +103,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertCount(1, $response->json()['data']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_individual_alias()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -119,7 +120,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertEquals($alias->email, $response->json()['data']['email']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_generate_new_alias()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/aliases', [
|
||||
|
@ -133,7 +134,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertEquals($this->user->aliases[0]->local_part, $response->getData()->data->local_part);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_generate_alias_with_recipients()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -158,7 +159,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertContains($recipient->email, $this->user->aliases[0]->recipients->pluck('email'));
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_generate_new_uuid_alias()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/aliases', [
|
||||
|
@ -174,7 +175,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertEquals($this->user->aliases[0]->id, $this->user->aliases[0]->local_part);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_generate_new_alias_with_local_part()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/aliases', [
|
||||
|
@ -190,7 +191,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertEquals('valid-local-part@'.$this->user->username.'.anonaddy.com', $this->user->aliases[0]->email);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_generate_new_alias_with_local_part_and_extension()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/aliases', [
|
||||
|
@ -207,7 +208,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertEquals('valid-local-part@'.$this->user->username.'.anonaddy.com', $this->user->aliases[0]->email);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_generate_new_alias_with_invalid_local_part()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/aliases', [
|
||||
|
@ -222,7 +223,7 @@ class AliasesTest extends TestCase
|
|||
$response->assertJsonValidationErrors('local_part_without_extension');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_generate_custom_alias_that_already_exists()
|
||||
{
|
||||
Alias::factory()->create([
|
||||
|
@ -245,7 +246,7 @@ class AliasesTest extends TestCase
|
|||
$response->assertJsonValidationErrors('local_part_without_extension');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_generate_new_random_word_alias()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/aliases', [
|
||||
|
@ -260,7 +261,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertNotEquals($this->user->aliases[0]->id, $this->user->aliases[0]->local_part);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_generate_new_alias_with_correct_aliasable_type()
|
||||
{
|
||||
Username::factory()->create([
|
||||
|
@ -285,7 +286,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertEquals($domain->id, $this->user->aliases[0]->aliasable_id);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_alias_description()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -300,7 +301,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertEquals('The new description', $response->getData()->data->description);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_alias_from_name()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -315,7 +316,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertEquals('John Doe', $response->getData()->data->from_name);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_delete_alias()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -330,7 +331,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertFalse($alias->refresh()->active);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_forget_alias()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -347,7 +348,7 @@ class AliasesTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_forget_shared_domain_alias()
|
||||
{
|
||||
$sharedDomainAlias = Alias::factory()->create([
|
||||
|
@ -381,7 +382,7 @@ class AliasesTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_restore_deleted_alias()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -395,7 +396,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertFalse($this->user->aliases[0]->trashed());
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_activate_alias()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -411,7 +412,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertEquals(true, $response->getData()->data->active);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_deactivate_alias()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -425,7 +426,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertFalse($this->user->aliases[0]->active);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_bulk_get_aliases()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -447,7 +448,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertCount(2, $response->getData()->data);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_bulk_get_invalid_aliases()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -464,7 +465,7 @@ class AliasesTest extends TestCase
|
|||
$this->assertEquals('No aliases found', $response->getData()->message);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_bulk_activate_aliases()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -493,7 +494,7 @@ class AliasesTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_bulk_activate_invalid_aliases()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -526,7 +527,7 @@ class AliasesTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_bulk_deactivate_aliases()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -555,7 +556,7 @@ class AliasesTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_bulk_delete_aliases()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -587,7 +588,7 @@ class AliasesTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_bulk_restore_aliases()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -619,7 +620,7 @@ class AliasesTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_bulk_forget_aliases()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -647,7 +648,7 @@ class AliasesTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_bulk_update_recipients_for_aliases()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
|
|
@ -4,6 +4,7 @@ namespace Tests\Feature\Api;
|
|||
|
||||
use App\Models\User;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class ApiTokenDetailsTest extends TestCase
|
||||
|
@ -15,7 +16,7 @@ class ApiTokenDetailsTest extends TestCase
|
|||
parent::setUp();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_account_details()
|
||||
{
|
||||
$user = User::factory()->create()->fresh();
|
||||
|
|
|
@ -5,6 +5,7 @@ namespace Tests\Feature\Api;
|
|||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Support\Facades\Hash;
|
||||
use Laravel\Sanctum\Sanctum;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class ApiTokensTest extends TestCase
|
||||
|
@ -21,7 +22,7 @@ class ApiTokensTest extends TestCase
|
|||
Sanctum::actingAs($this->user, [], 'web');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_create_api_token()
|
||||
{
|
||||
$response = $this->post('/settings/personal-access-tokens', [
|
||||
|
@ -38,7 +39,7 @@ class ApiTokensTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_create_api_token_with_incorrect_password()
|
||||
{
|
||||
$response = $this->post('/settings/personal-access-tokens', [
|
||||
|
@ -56,7 +57,7 @@ class ApiTokensTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_revoke_api_token()
|
||||
{
|
||||
$token = $this->user->createToken('New');
|
||||
|
|
|
@ -4,6 +4,7 @@ namespace Tests\Feature\Api;
|
|||
|
||||
use App\Helpers\GitVersionHelper as Version;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class AppVersionTest extends TestCase
|
||||
|
@ -16,7 +17,7 @@ class AppVersionTest extends TestCase
|
|||
parent::setUpSanctum();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_app_version()
|
||||
{
|
||||
$response = $this->json('GET', '/api/v1/app-version');
|
||||
|
|
|
@ -5,6 +5,7 @@ namespace Tests\Feature\Api;
|
|||
use App\Models\Domain;
|
||||
use App\Models\Recipient;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class DomainsTest extends TestCase
|
||||
|
@ -17,7 +18,7 @@ class DomainsTest extends TestCase
|
|||
parent::setUpSanctum();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_all_domains()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -33,7 +34,7 @@ class DomainsTest extends TestCase
|
|||
$this->assertCount(3, $response->json()['data']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_individual_domain()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -50,7 +51,7 @@ class DomainsTest extends TestCase
|
|||
$this->assertEquals($domain->domain, $response->json()['data']['domain']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_create_new_domain()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/domains', [
|
||||
|
@ -61,7 +62,7 @@ class DomainsTest extends TestCase
|
|||
$this->assertEquals('random.com', $response->getData()->data->domain);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_not_create_the_same_domain()
|
||||
{
|
||||
Domain::factory()->create([
|
||||
|
@ -78,7 +79,7 @@ class DomainsTest extends TestCase
|
|||
->assertJsonValidationErrors('domain');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function new_domain_must_be_a_valid_fqdn()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/domains', [
|
||||
|
@ -90,7 +91,7 @@ class DomainsTest extends TestCase
|
|||
->assertJsonValidationErrors('domain');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function new_domain_must_not_include_protocol()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/domains', [
|
||||
|
@ -102,7 +103,7 @@ class DomainsTest extends TestCase
|
|||
->assertJsonValidationErrors('domain');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function new_domain_must_not_be_local()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/domains', [
|
||||
|
@ -114,7 +115,7 @@ class DomainsTest extends TestCase
|
|||
->assertJsonValidationErrors('domain');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function new_domain_must_not_be_local_subdomain()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/domains', [
|
||||
|
@ -126,7 +127,7 @@ class DomainsTest extends TestCase
|
|||
->assertJsonValidationErrors('domain');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_activate_domain()
|
||||
{
|
||||
$domain = Domain::factory()->create([
|
||||
|
@ -142,7 +143,7 @@ class DomainsTest extends TestCase
|
|||
$this->assertEquals(true, $response->getData()->data->active);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_deactivate_domain()
|
||||
{
|
||||
$domain = Domain::factory()->create([
|
||||
|
@ -156,7 +157,7 @@ class DomainsTest extends TestCase
|
|||
$this->assertFalse($this->user->domains[0]->active);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_enable_catch_all_for_domain()
|
||||
{
|
||||
$domain = Domain::factory()->create([
|
||||
|
@ -172,7 +173,7 @@ class DomainsTest extends TestCase
|
|||
$this->assertTrue($response->getData()->data->catch_all);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_disable_catch_all_for_domain()
|
||||
{
|
||||
$domain = Domain::factory()->create([
|
||||
|
@ -186,7 +187,7 @@ class DomainsTest extends TestCase
|
|||
$this->assertFalse($this->user->domains[0]->catch_all);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_domain_description()
|
||||
{
|
||||
$domain = Domain::factory()->create([
|
||||
|
@ -201,7 +202,7 @@ class DomainsTest extends TestCase
|
|||
$this->assertEquals('The new description', $response->getData()->data->description);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_domain_from_name()
|
||||
{
|
||||
$domain = Domain::factory()->create([
|
||||
|
@ -216,7 +217,7 @@ class DomainsTest extends TestCase
|
|||
$this->assertEquals('John Doe', $response->getData()->data->from_name);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_delete_domain()
|
||||
{
|
||||
$domain = Domain::factory()->create([
|
||||
|
@ -229,7 +230,7 @@ class DomainsTest extends TestCase
|
|||
$this->assertEmpty($this->user->domains);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_domain_default_recipient()
|
||||
{
|
||||
$domain = Domain::factory()->create([
|
||||
|
@ -254,7 +255,7 @@ class DomainsTest extends TestCase
|
|||
$this->assertEquals($newDefaultRecipient->email, $domain->refresh()->defaultRecipient->email);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_update_domain_default_recipient_with_unverified_recipient()
|
||||
{
|
||||
$domain = Domain::factory()->create([
|
||||
|
@ -278,7 +279,7 @@ class DomainsTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_remove_domain_default_recipient()
|
||||
{
|
||||
$defaultRecipient = Recipient::factory()->create([
|
||||
|
|
|
@ -4,6 +4,7 @@ namespace Tests\Feature\Api;
|
|||
|
||||
use App\Models\FailedDelivery;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class FailedDeliveriesTest extends TestCase
|
||||
|
@ -18,7 +19,7 @@ class FailedDeliveriesTest extends TestCase
|
|||
$this->user->recipients()->save($this->user->defaultRecipient);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_all_failed_deliveries()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -34,7 +35,7 @@ class FailedDeliveriesTest extends TestCase
|
|||
$this->assertCount(3, $response->json()['data']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_individual_failed_delivery()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -51,7 +52,7 @@ class FailedDeliveriesTest extends TestCase
|
|||
$this->assertEquals($failedDelivery->code, $response->json()['data']['code']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_delete_failed_delivery()
|
||||
{
|
||||
$failedDelivery = FailedDelivery::factory()->create([
|
||||
|
|
|
@ -6,6 +6,7 @@ use App\Models\Domain;
|
|||
use App\Models\Recipient;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Support\Facades\Notification;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class RecipientsTest extends TestCase
|
||||
|
@ -18,7 +19,7 @@ class RecipientsTest extends TestCase
|
|||
parent::setUpSanctum();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_all_recipients()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -34,7 +35,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertCount(4, $response->json()['data']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_individual_recipient()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -51,7 +52,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertEquals($recipient->email, $response->json()['data']['email']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_create_new_recipient()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/recipients', [
|
||||
|
@ -62,7 +63,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertEquals('johndoe@example.com', $response->getData()->data->email);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_create_auto_verified_recipient()
|
||||
{
|
||||
Notification::fake();
|
||||
|
@ -87,7 +88,7 @@ class RecipientsTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_not_create_the_same_recipient()
|
||||
{
|
||||
Recipient::factory()->create([
|
||||
|
@ -104,7 +105,7 @@ class RecipientsTest extends TestCase
|
|||
->assertJsonValidationErrors('email');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_not_create_the_same_recipient_in_uppercase()
|
||||
{
|
||||
Recipient::factory()->create([
|
||||
|
@ -121,7 +122,7 @@ class RecipientsTest extends TestCase
|
|||
->assertJsonValidationErrors('email');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_not_create_the_same_recipient_as_default()
|
||||
{
|
||||
$this->user->recipients()->save($this->user->defaultRecipient);
|
||||
|
@ -135,7 +136,7 @@ class RecipientsTest extends TestCase
|
|||
->assertJsonValidationErrors('email');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_not_create_recipient_with_local_domain()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/recipients', [
|
||||
|
@ -147,7 +148,7 @@ class RecipientsTest extends TestCase
|
|||
->assertJsonValidationErrors('email');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_not_create_recipient_with_local_custom_domain()
|
||||
{
|
||||
Domain::factory()->create([
|
||||
|
@ -165,7 +166,7 @@ class RecipientsTest extends TestCase
|
|||
->assertJsonValidationErrors('email');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function new_recipient_must_have_valid_email()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/recipients', [
|
||||
|
@ -177,7 +178,7 @@ class RecipientsTest extends TestCase
|
|||
->assertJsonValidationErrors('email');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_delete_recipient()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -190,7 +191,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertCount(1, $this->user->recipients);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_not_delete_default_recipient()
|
||||
{
|
||||
$this->user->recipients()->save($this->user->defaultRecipient);
|
||||
|
@ -204,7 +205,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertEquals($defaultRecipient->id, $this->user->defaultRecipient->id);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_add_gpg_key_to_recipient()
|
||||
{
|
||||
$gnupg = new \gnupg();
|
||||
|
@ -222,7 +223,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertTrue($response->getData()->data->should_encrypt);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function gpg_key_must_be_correct_format()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -238,7 +239,7 @@ class RecipientsTest extends TestCase
|
|||
->assertJsonValidationErrors('key_data');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function gpg_key_must_be_valid()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -253,7 +254,7 @@ class RecipientsTest extends TestCase
|
|||
->assertStatus(404);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_remove_gpg_key_from_recipient()
|
||||
{
|
||||
$gnupg = new \gnupg();
|
||||
|
@ -272,7 +273,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertFalse($this->user->recipients[0]->should_encrypt);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_turn_on_encryption_for_recipient()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -289,7 +290,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertEquals(true, $response->getData()->data->should_encrypt);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_turn_off_encryption_for_recipient()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -304,7 +305,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertFalse($this->user->recipients[0]->should_encrypt);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_allow_recipient_to_send_or_reply()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -320,7 +321,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertEquals(true, $response->getData()->data->can_reply_send);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_disallow_recipient_from_sending_or_replying()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -334,7 +335,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertFalse($this->user->recipients[1]->can_reply_send);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_turn_on_inline_encryption()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -351,7 +352,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertEquals(true, $response->getData()->data->inline_encryption);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_turn_off_inline_encryption()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -366,7 +367,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertFalse($this->user->recipients[0]->inline_encryption);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_turn_on_protected_headers()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -383,7 +384,7 @@ class RecipientsTest extends TestCase
|
|||
$this->assertEquals(true, $response->getData()->data->protected_headers);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_turn_off_protected_headers()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
|
|
@ -9,6 +9,7 @@ use App\Models\Rule;
|
|||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Support\Str;
|
||||
use PhpMimeMailParser\Parser;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class RulesTest extends TestCase
|
||||
|
@ -24,7 +25,7 @@ class RulesTest extends TestCase
|
|||
$this->user->defaultUsername->save();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_all_rules()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -40,7 +41,7 @@ class RulesTest extends TestCase
|
|||
$this->assertCount(3, $response->json()['data']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_individual_rule()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -57,7 +58,7 @@ class RulesTest extends TestCase
|
|||
$this->assertEquals($rule->name, $response->json()['data']['name']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_create_new_rule()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/rules', [
|
||||
|
@ -101,7 +102,7 @@ class RulesTest extends TestCase
|
|||
$this->assertEquals('test rule', $response->getData()->data->name);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_create_invalid_rule()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/rules', [
|
||||
|
@ -130,7 +131,7 @@ class RulesTest extends TestCase
|
|||
$response->assertStatus(422);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_rule()
|
||||
{
|
||||
$rule = Rule::factory()->create([
|
||||
|
@ -166,7 +167,7 @@ class RulesTest extends TestCase
|
|||
$this->assertEquals('OR', $response->getData()->data->operator);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_delete_rule()
|
||||
{
|
||||
$rule = Rule::factory()->create([
|
||||
|
@ -179,7 +180,7 @@ class RulesTest extends TestCase
|
|||
$this->assertEmpty($this->user->rules);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_activate_rule()
|
||||
{
|
||||
$rule = Rule::factory()->create([
|
||||
|
@ -195,7 +196,7 @@ class RulesTest extends TestCase
|
|||
$this->assertEquals(true, $response->getData()->data->active);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_deactivate_rule()
|
||||
{
|
||||
$rule = Rule::factory()->create([
|
||||
|
@ -209,7 +210,7 @@ class RulesTest extends TestCase
|
|||
$this->assertFalse($this->user->rules[0]->active);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_apply_user_rules()
|
||||
{
|
||||
$rule = Rule::factory()->create([
|
||||
|
@ -280,7 +281,7 @@ class RulesTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_does_not_apply_rules_if_email_type_is_not_selected()
|
||||
{
|
||||
$rule = Rule::factory()->create([
|
||||
|
@ -349,7 +350,7 @@ class RulesTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_apply_user_rules_in_correct_order()
|
||||
{
|
||||
Rule::factory()->create([
|
||||
|
@ -435,7 +436,7 @@ class RulesTest extends TestCase
|
|||
$this->assertEquals('Applied after', $email->subject);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_reorder_rules()
|
||||
{
|
||||
$ruleOne = Rule::factory()->create([
|
||||
|
@ -517,12 +518,12 @@ class RulesTest extends TestCase
|
|||
|
||||
if ($file === 'stream') {
|
||||
$fd = fopen('php://stdin', 'r');
|
||||
$this->rawEmail = '';
|
||||
$rawEmail = '';
|
||||
while (! feof($fd)) {
|
||||
$this->rawEmail .= fread($fd, 1024);
|
||||
$rawEmail .= fread($fd, 1024);
|
||||
}
|
||||
fclose($fd);
|
||||
$parser->setText($this->rawEmail);
|
||||
$parser->setText($rawEmail);
|
||||
} else {
|
||||
$parser->setPath($file);
|
||||
}
|
||||
|
|
|
@ -7,6 +7,7 @@ use App\Models\Recipient;
|
|||
use App\Models\User;
|
||||
use App\Models\Username;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class UsernamesTest extends TestCase
|
||||
|
@ -22,7 +23,7 @@ class UsernamesTest extends TestCase
|
|||
$this->user->defaultUsername->save();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_all_usernames()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -38,7 +39,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertCount(4, $response->json()['data']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_individual_username()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -55,7 +56,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertEquals($username->username, $response->json()['data']['username']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_create_username()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/usernames', [
|
||||
|
@ -67,7 +68,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertEquals(1, $this->user->username_count);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_not_exceed_username_limit()
|
||||
{
|
||||
$this->json('POST', '/api/v1/usernames', [
|
||||
|
@ -91,7 +92,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertCount(4, $this->user->usernames);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_not_create_the_same_username()
|
||||
{
|
||||
Username::factory()->create([
|
||||
|
@ -108,7 +109,7 @@ class UsernamesTest extends TestCase
|
|||
->assertJsonValidationErrors('username');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_not_create_username_that_has_been_deleted()
|
||||
{
|
||||
DeletedUsername::factory()->create([
|
||||
|
@ -124,7 +125,7 @@ class UsernamesTest extends TestCase
|
|||
->assertJsonValidationErrors('username');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function must_be_unique_across_users_and_usernames_tables()
|
||||
{
|
||||
$user = User::factory()->create()->fresh();
|
||||
|
@ -138,7 +139,7 @@ class UsernamesTest extends TestCase
|
|||
->assertJsonValidationErrors('username');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function username_must_be_alpha_numeric()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/usernames', [
|
||||
|
@ -150,7 +151,7 @@ class UsernamesTest extends TestCase
|
|||
->assertJsonValidationErrors('username');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function username_must_be_less_than_max_length()
|
||||
{
|
||||
$response = $this->json('POST', '/api/v1/usernames', [
|
||||
|
@ -162,7 +163,7 @@ class UsernamesTest extends TestCase
|
|||
->assertJsonValidationErrors('username');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_activate_username()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -178,7 +179,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertEquals(true, $response->getData()->data->active);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_deactivate_username()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -192,7 +193,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertFalse($this->user->usernames[1]->active);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_enable_catch_all_for_username()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -208,7 +209,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertTrue($response->getData()->data->catch_all);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_disable_catch_all_for_username()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -222,7 +223,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertFalse($this->user->usernames[1]->catch_all);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_allow_login_for_username()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -238,7 +239,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertTrue($response->getData()->data->can_login);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_disallow_login_for_username()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -252,7 +253,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertFalse($this->user->usernames[1]->can_login);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_disallow_login_for_default_username()
|
||||
{
|
||||
$username = $this->user->defaultUsername;
|
||||
|
@ -263,7 +264,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertTrue($this->user->usernames[0]->can_login);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_usernames_description()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -278,7 +279,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertEquals('The new description', $response->getData()->data->description);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_username_from_name()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -293,7 +294,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertEquals('John Doe', $response->getData()->data->from_name);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_delete_username()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -308,7 +309,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertEquals(DeletedUsername::first()->username, $username->username);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_not_delete_default_username()
|
||||
{
|
||||
$this->user->usernames()->save($this->user->defaultUsername);
|
||||
|
@ -322,7 +323,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertEquals($defaultUsername->id, $this->user->defaultUsername->id);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_username_default_recipient()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -346,7 +347,7 @@ class UsernamesTest extends TestCase
|
|||
$this->assertEquals($newDefaultRecipient->email, $username->refresh()->defaultRecipient->email);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_update_username_default_recipient_with_unverified_recipient()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -369,7 +370,7 @@ class UsernamesTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_remove_username_default_recipient()
|
||||
{
|
||||
$defaultRecipient = Recipient::factory()->create([
|
||||
|
|
|
@ -5,6 +5,7 @@ namespace Tests\Feature;
|
|||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Routing\Middleware\ThrottleRequestsWithRedis;
|
||||
use Illuminate\Support\Facades\Hash;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class ApiAuthenticationTest extends TestCase
|
||||
|
@ -20,7 +21,7 @@ class ApiAuthenticationTest extends TestCase
|
|||
$this->user = $this->createUser('johndoe', null, ['password' => Hash::make('mypassword')]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_retreive_valid_access_token()
|
||||
{
|
||||
$this->withoutMiddleware(ThrottleRequestsWithRedis::class);
|
||||
|
@ -35,7 +36,7 @@ class ApiAuthenticationTest extends TestCase
|
|||
$this->assertEquals($this->user->tokens[0]->token, hash('sha256', $response->json()['api_key']));
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_password_must_be_correct_to_get_access_token()
|
||||
{
|
||||
$this->withoutMiddleware(ThrottleRequestsWithRedis::class);
|
||||
|
@ -49,7 +50,7 @@ class ApiAuthenticationTest extends TestCase
|
|||
$response->assertUnauthorized();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_must_exist_to_get_access_token()
|
||||
{
|
||||
$this->withoutMiddleware(ThrottleRequestsWithRedis::class);
|
||||
|
@ -64,7 +65,7 @@ class ApiAuthenticationTest extends TestCase
|
|||
$response->assertExactJson(['error' => 'The provided credentials are incorrect']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_is_throttled_by_middleware_for_too_many_requests()
|
||||
{
|
||||
$this->json('POST', '/api/auth/login', [
|
||||
|
@ -94,7 +95,7 @@ class ApiAuthenticationTest extends TestCase
|
|||
$response->assertStatus(429);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_get_access_token_with_webauthn_enabled()
|
||||
{
|
||||
$this->withoutMiddleware(ThrottleRequestsWithRedis::class);
|
||||
|
@ -122,7 +123,7 @@ class ApiAuthenticationTest extends TestCase
|
|||
$response->assertExactJson(['error' => 'Security key authentication is not currently supported from the extension or mobile apps, please use an API key to login instead']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_must_provide_correct_otp_if_enabled()
|
||||
{
|
||||
$this->withoutMiddleware(ThrottleRequestsWithRedis::class);
|
||||
|
|
|
@ -6,9 +6,11 @@ use App\Enums\LoginRedirect;
|
|||
use App\Models\Username;
|
||||
use App\Notifications\UsernameReminder;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Routing\Middleware\ThrottleRequestsWithRedis;
|
||||
use Illuminate\Support\Facades\Hash;
|
||||
use Illuminate\Support\Facades\Notification;
|
||||
use Illuminate\Support\Str;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class LoginTest extends TestCase
|
||||
|
@ -24,7 +26,7 @@ class LoginTest extends TestCase
|
|||
$this->user = $this->createUser('johndoe', null, ['password' => Hash::make('mypassword')]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_login_successfully()
|
||||
{
|
||||
$response = $this->post('/login', [
|
||||
|
@ -37,7 +39,7 @@ class LoginTest extends TestCase
|
|||
->assertSessionHasNoErrors();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_login_and_be_redirected_based_on_login_redirect_successfully()
|
||||
{
|
||||
$this->withoutMiddleware(ThrottleRequestsWithRedis::class);
|
||||
|
@ -55,7 +57,7 @@ class LoginTest extends TestCase
|
|||
->assertSessionHasNoErrors();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_login_with_any_username()
|
||||
{
|
||||
$username = Username::factory()->create([
|
||||
|
@ -72,7 +74,7 @@ class LoginTest extends TestCase
|
|||
->assertSessionHasNoErrors();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_login_successfully_using_backup_code()
|
||||
{
|
||||
$this->user->update([
|
||||
|
@ -107,7 +109,7 @@ class LoginTest extends TestCase
|
|||
->assertSessionHasNoErrors();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_receive_username_reminder_email()
|
||||
{
|
||||
$this->withoutMiddleware();
|
||||
|
@ -126,7 +128,7 @@ class LoginTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function username_reminder_email_not_sent_for_unkown_email()
|
||||
{
|
||||
$this->withoutMiddleware();
|
||||
|
|
|
@ -13,6 +13,7 @@ use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
|||
use Illuminate\Support\Facades\Cache;
|
||||
use Illuminate\Support\Facades\Mail;
|
||||
use Illuminate\Support\Facades\Notification;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class ReceiveEmailTest extends TestCase
|
||||
|
@ -28,7 +29,7 @@ class ReceiveEmailTest extends TestCase
|
|||
$this->user = $this->createUser('johndoe');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_from_file()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -64,7 +65,7 @@ class ReceiveEmailTest extends TestCase
|
|||
Notification::assertNothingSent();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_from_file_with_capitals()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -97,7 +98,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_from_file_with_attachment()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -130,7 +131,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_from_file_to_multiple_recipients()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -175,7 +176,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_from_file_with_extension()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -209,7 +210,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_with_existing_alias()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -250,7 +251,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_with_uuid_generated_alias()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -300,7 +301,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_with_random_word_generated_alias()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -349,7 +350,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_with_existing_alias_and_receipients()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -410,7 +411,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_attach_recipients_to_new_alias_with_extension()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -455,7 +456,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_not_attach_unverified_recipient_to_new_alias_with_extension()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -500,7 +501,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_does_not_send_email_if_default_recipient_has_not_yet_been_verified()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -532,7 +533,7 @@ class ReceiveEmailTest extends TestCase
|
|||
Mail::assertNotQueued(ForwardEmail::class);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_unsubscribe_alias_by_emailing_list_unsubscribe()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -584,7 +585,7 @@ class ReceiveEmailTest extends TestCase
|
|||
Mail::assertNotQueued(ForwardEmail::class);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_cannot_unsubscribe_alias_if_not_a_verified_user_recipient()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -631,7 +632,7 @@ class ReceiveEmailTest extends TestCase
|
|||
Mail::assertNotQueued(ForwardEmail::class);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_to_admin_username_for_root_domain()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -667,7 +668,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_for_custom_domain()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -709,7 +710,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_for_custom_domain_with_verified_sending()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -752,7 +753,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_for_username()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -793,7 +794,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_send_near_bandwidth_limit_notification()
|
||||
{
|
||||
Notification::fake();
|
||||
|
@ -829,7 +830,7 @@ class ReceiveEmailTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_does_not_send_near_bandwidth_limit_notification_more_than_once_per_day()
|
||||
{
|
||||
Notification::fake();
|
||||
|
@ -872,7 +873,7 @@ class ReceiveEmailTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_from_file_for_all_domains()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -905,7 +906,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_for_custom_domain_with_default_recipient()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -952,7 +953,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_for_username_with_default_recipient()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -998,7 +999,7 @@ class ReceiveEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_forward_email_using_old_reply_to_and_from_headers()
|
||||
{
|
||||
Mail::fake();
|
||||
|
|
|
@ -13,13 +13,14 @@ use Illuminate\Support\Facades\Config;
|
|||
use Illuminate\Support\Facades\Hash;
|
||||
use Illuminate\Support\Facades\Notification;
|
||||
use Illuminate\Support\Facades\URL;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class RegistrationTest extends TestCase
|
||||
{
|
||||
use LazilyRefreshDatabase;
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_register_successfully()
|
||||
{
|
||||
Notification::fake();
|
||||
|
@ -48,7 +49,7 @@ class RegistrationTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_register_with_invalid_characters()
|
||||
{
|
||||
$response = $this->post('/register', [
|
||||
|
@ -66,7 +67,7 @@ class RegistrationTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_verify_email_successfully()
|
||||
{
|
||||
$user = User::factory()->create()->fresh();
|
||||
|
@ -93,7 +94,7 @@ class RegistrationTest extends TestCase
|
|||
$this->assertNotNull($user->refresh()->email_verified_at);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_must_use_valid_username()
|
||||
{
|
||||
$response = $this->post('/register', [
|
||||
|
@ -110,7 +111,7 @@ class RegistrationTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_must_confirm_email()
|
||||
{
|
||||
$response = $this->post('/register', [
|
||||
|
@ -127,7 +128,7 @@ class RegistrationTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_register_with_existing_email()
|
||||
{
|
||||
$user = User::factory()->create()->fresh();
|
||||
|
@ -153,7 +154,7 @@ class RegistrationTest extends TestCase
|
|||
$response->assertSessionHasErrors(['email']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_register_with_existing_username()
|
||||
{
|
||||
$user = User::factory()->create()->fresh();
|
||||
|
@ -174,7 +175,7 @@ class RegistrationTest extends TestCase
|
|||
$response->assertSessionHasErrors(['username']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_register_with_blacklisted_username()
|
||||
{
|
||||
$response = $this->post('/register', [
|
||||
|
@ -192,7 +193,7 @@ class RegistrationTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_register_with_uppercase_blacklisted_username()
|
||||
{
|
||||
$response = $this->post('/register', [
|
||||
|
@ -210,7 +211,7 @@ class RegistrationTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_register_with_deleted_username()
|
||||
{
|
||||
DeletedUsername::create(['username' => 'johndoe']);
|
||||
|
@ -230,7 +231,7 @@ class RegistrationTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_register_with_uppercase_deleted_username()
|
||||
{
|
||||
DeletedUsername::create(['username' => 'johndoe']);
|
||||
|
|
|
@ -7,6 +7,7 @@ use App\Models\Alias;
|
|||
use App\Models\Recipient;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Support\Facades\Mail;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class ReplyToEmailTest extends TestCase
|
||||
|
@ -22,7 +23,7 @@ class ReplyToEmailTest extends TestCase
|
|||
$this->user = $this->createUser('johndoe', 'will@anonaddy.com');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_reply_to_email_from_file()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -58,7 +59,7 @@ class ReplyToEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_cannot_reply_using_unverified_recipient()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -104,7 +105,7 @@ class ReplyToEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_reply_to_multiple_emails_from_file()
|
||||
{
|
||||
Mail::fake();
|
||||
|
|
|
@ -6,6 +6,7 @@ use App\Mail\SendFromEmail;
|
|||
use App\Models\Alias;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Support\Facades\Mail;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class SendFromEmailTest extends TestCase
|
||||
|
@ -21,7 +22,7 @@ class SendFromEmailTest extends TestCase
|
|||
$this->user = $this->createUser('johndoe', 'will@anonaddy.com');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_send_email_from_alias_from_file()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -57,7 +58,7 @@ class SendFromEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_send_from_alias_to_multiple_emails_from_file()
|
||||
{
|
||||
Mail::fake();
|
||||
|
@ -101,7 +102,7 @@ class SendFromEmailTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_send_email_from_catch_all_alias_that_does_not_yet_exist()
|
||||
{
|
||||
Mail::fake();
|
||||
|
|
|
@ -19,6 +19,7 @@ use Illuminate\Support\Facades\Hash;
|
|||
use Illuminate\Support\Facades\Notification;
|
||||
use Illuminate\Support\Str;
|
||||
use Maatwebsite\Excel\Facades\Excel;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class SettingsTest extends TestCase
|
||||
|
@ -35,7 +36,7 @@ class SettingsTest extends TestCase
|
|||
$this->actingAs($this->user);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_default_recipient()
|
||||
{
|
||||
Notification::fake();
|
||||
|
@ -64,7 +65,7 @@ class SettingsTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_update_to_unverified_default_recipient()
|
||||
{
|
||||
$newDefaultRecipient = Recipient::factory()->create([
|
||||
|
@ -82,7 +83,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertNotEquals($this->user->default_recipient_id, $newDefaultRecipient->id);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_edit_default_recipient()
|
||||
{
|
||||
Notification::fake();
|
||||
|
@ -117,7 +118,7 @@ class SettingsTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_must_enter_current_password_to_edit_default_recipient()
|
||||
{
|
||||
Notification::fake();
|
||||
|
@ -136,7 +137,7 @@ class SettingsTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_default_username()
|
||||
{
|
||||
$currentDefaultUsername = $this->user->defaultUsername;
|
||||
|
@ -164,7 +165,7 @@ class SettingsTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_default_alias_domain()
|
||||
{
|
||||
$defaultAliasDomain = $this->user->username.'.anonaddy.me';
|
||||
|
@ -180,7 +181,7 @@ class SettingsTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_update_default_alias_domain_if_invalid()
|
||||
{
|
||||
$response = $this->post('/settings/default-alias-domain', [
|
||||
|
@ -195,7 +196,7 @@ class SettingsTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_default_alias_format()
|
||||
{
|
||||
$defaultAliasFormat = 'random_words';
|
||||
|
@ -211,7 +212,7 @@ class SettingsTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_update_default_alias_format_if_invalid()
|
||||
{
|
||||
$response = $this->post('/settings/default-alias-format', [
|
||||
|
@ -226,7 +227,7 @@ class SettingsTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_display_from_format()
|
||||
{
|
||||
$displayFromFormat = DisplayFromFormat::DEFAULT->value;
|
||||
|
@ -242,7 +243,7 @@ class SettingsTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_update_display_from_format_if_invalid()
|
||||
{
|
||||
$response = $this->post('/settings/display-from-format', [
|
||||
|
@ -257,7 +258,7 @@ class SettingsTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_reply_from_name()
|
||||
{
|
||||
$this->assertNull($this->user->from_name);
|
||||
|
@ -270,7 +271,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertEquals('John Doe', $this->user->from_name);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_reply_from_name_to_empty()
|
||||
{
|
||||
$this->assertNull($this->user->from_name);
|
||||
|
@ -283,7 +284,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertEquals(null, $this->user->from_name);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_email_subject()
|
||||
{
|
||||
$this->assertNull($this->user->email_subject);
|
||||
|
@ -296,7 +297,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertEquals('The subject', $this->user->email_subject);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_email_subject_to_empty()
|
||||
{
|
||||
$this->assertNull($this->user->email_subject);
|
||||
|
@ -309,7 +310,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertEquals(null, $this->user->email_subject);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_update_email_banner_location()
|
||||
{
|
||||
$this->assertEquals('top', $this->user->banner_location);
|
||||
|
@ -322,7 +323,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertEquals('bottom', $this->user->banner_location);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_cannot_update_email_banner_location_to_incorrect_value()
|
||||
{
|
||||
$this->assertEquals('top', $this->user->banner_location);
|
||||
|
@ -337,7 +338,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertEquals('top', $this->user->banner_location);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_enable_use_reply_to()
|
||||
{
|
||||
$this->assertFalse($this->user->use_reply_to);
|
||||
|
@ -350,7 +351,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertTrue($this->user->use_reply_to);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_disable_use_reply_to()
|
||||
{
|
||||
$this->user->update(['use_reply_to' => true]);
|
||||
|
@ -365,7 +366,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertFalse($this->user->use_reply_to);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_enable_store_failed_deliveries()
|
||||
{
|
||||
$this->user->update(['store_failed_deliveries' => false]);
|
||||
|
@ -378,7 +379,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertTrue($this->user->store_failed_deliveries);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_disable_store_failed_deliveries()
|
||||
{
|
||||
$this->assertTrue($this->user->store_failed_deliveries);
|
||||
|
@ -391,7 +392,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertFalse($this->user->store_failed_deliveries);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_enable_save_alias_last_used()
|
||||
{
|
||||
$this->user->update(['save_alias_last_used' => false]);
|
||||
|
@ -406,7 +407,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertTrue($this->user->save_alias_last_used);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_disable_save_alias_last_used()
|
||||
{
|
||||
$this->assertTrue($this->user->save_alias_last_used);
|
||||
|
@ -419,7 +420,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertFalse($this->user->save_alias_last_used);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_generate_new_backup_code()
|
||||
{
|
||||
$this->user->update([
|
||||
|
@ -439,7 +440,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertNotEquals($currentBackupCode, $this->user->two_factor_backup_code);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_must_enter_current_password_to_generate_new_backup_code()
|
||||
{
|
||||
$this->user->update([
|
||||
|
@ -460,7 +461,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertEquals($currentBackupCode, $this->user->two_factor_backup_code);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_enable_webauthn_key()
|
||||
{
|
||||
$key = $this->user->webauthnKeys()->create([
|
||||
|
@ -486,7 +487,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertTrue($this->user->webauthnKeys[0]->enabled);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_disable_webauthn_key()
|
||||
{
|
||||
$key = $this->user->webauthnKeys()->create([
|
||||
|
@ -512,7 +513,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertFalse($this->user->webauthnKeys[0]->enabled);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_must_enter_correct_password_to_disable_webauthn_key()
|
||||
{
|
||||
$key = $this->user->webauthnKeys()->create([
|
||||
|
@ -540,7 +541,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertTrue($this->user->webauthnKeys[0]->enabled);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_delete_webauthn_key()
|
||||
{
|
||||
$key = $this->user->webauthnKeys()->create([
|
||||
|
@ -568,7 +569,7 @@ class SettingsTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_must_enter_correct_password_to_delete_webauthn_key()
|
||||
{
|
||||
$key = $this->user->webauthnKeys()->create([
|
||||
|
@ -598,7 +599,7 @@ class SettingsTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_delete_account()
|
||||
{
|
||||
$this->assertNotNull($this->user->id);
|
||||
|
@ -718,7 +719,7 @@ class SettingsTest extends TestCase
|
|||
$this->assertEquals(DeletedUsername::skip(1)->first()->username, $username->username);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_must_enter_correct_password_to_delete_account()
|
||||
{
|
||||
$this->assertNotNull($this->user->id);
|
||||
|
@ -745,9 +746,7 @@ class SettingsTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/**
|
||||
* @test
|
||||
*/
|
||||
#[Test]
|
||||
public function user_can_import_aliases_for_custom_domains()
|
||||
{
|
||||
Excel::fake();
|
||||
|
@ -771,9 +770,7 @@ class SettingsTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* @test
|
||||
*/
|
||||
#[Test]
|
||||
public function user_can_download_aliases_export()
|
||||
{
|
||||
Excel::fake();
|
||||
|
|
|
@ -8,6 +8,7 @@ use App\Models\Recipient;
|
|||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Support\Carbon;
|
||||
use Inertia\Testing\AssertableInertia as Assert;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class ShowAliasesTest extends TestCase
|
||||
|
@ -24,7 +25,7 @@ class ShowAliasesTest extends TestCase
|
|||
$this->actingAs($this->user);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_view_aliases_from_the_dashboard()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -45,7 +46,7 @@ class ShowAliasesTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function latest_aliases_are_listed_first()
|
||||
{
|
||||
// Arrange
|
||||
|
@ -78,7 +79,7 @@ class ShowAliasesTest extends TestCase
|
|||
$this->assertTrue($response->data('page')['props']['initialRows']['data'][2]['id'] === $a->id);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function deleted_aliases_are_not_listed()
|
||||
{
|
||||
Alias::factory()->count(3)->create([
|
||||
|
@ -101,7 +102,7 @@ class ShowAliasesTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function aliases_are_listed_with_recipients()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -129,7 +130,7 @@ class ShowAliasesTest extends TestCase
|
|||
$this->assertEquals($aliasRecipient->recipient->email, $response->data('page')['props']['initialRows']['data'][0]['recipients'][0]['email']);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function aliases_are_listed_with_only_verified_recipient_options()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
|
|
@ -6,6 +6,7 @@ use App\Models\Domain;
|
|||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Support\Carbon;
|
||||
use Inertia\Testing\AssertableInertia as Assert;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class ShowDomainsTest extends TestCase
|
||||
|
@ -22,7 +23,7 @@ class ShowDomainsTest extends TestCase
|
|||
$this->actingAs($this->user);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_view_domains_from_the_domains_page()
|
||||
{
|
||||
Domain::factory()->count(3)->create([
|
||||
|
@ -40,7 +41,7 @@ class ShowDomainsTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function latest_domains_are_listed_first()
|
||||
{
|
||||
$a = Domain::factory()->create([
|
||||
|
@ -70,7 +71,7 @@ class ShowDomainsTest extends TestCase
|
|||
$this->assertTrue($response->data('page')['props']['initialRows'][2]['id'] === $a->id);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_verify_domain_sending_records()
|
||||
{
|
||||
$domain = Domain::factory()->create([
|
||||
|
|
|
@ -6,6 +6,7 @@ use App\Models\FailedDelivery;
|
|||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Support\Carbon;
|
||||
use Inertia\Testing\AssertableInertia as Assert;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class ShowFailedDeliveriesTest extends TestCase
|
||||
|
@ -22,7 +23,7 @@ class ShowFailedDeliveriesTest extends TestCase
|
|||
$this->actingAs($this->user);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_view_failed_deliveries_from_the_failed_deliveries_page()
|
||||
{
|
||||
FailedDelivery::factory()->count(3)->create([
|
||||
|
@ -40,7 +41,7 @@ class ShowFailedDeliveriesTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function latest_failed_deliveries_are_listed_first()
|
||||
{
|
||||
$a = FailedDelivery::factory()->create([
|
||||
|
|
|
@ -2,10 +2,7 @@
|
|||
|
||||
namespace Tests\Feature;
|
||||
|
||||
use App\Models\Alias;
|
||||
use App\Models\AliasRecipient;
|
||||
use App\Models\Recipient;
|
||||
use App\Models\User;
|
||||
use App\Notifications\CustomVerifyEmail;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Support\Carbon;
|
||||
|
@ -14,6 +11,7 @@ use Illuminate\Support\Facades\Hash;
|
|||
use Illuminate\Support\Facades\Notification;
|
||||
use Illuminate\Support\Facades\URL;
|
||||
use Inertia\Testing\AssertableInertia as Assert;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class ShowRecipientsTest extends TestCase
|
||||
|
@ -30,7 +28,7 @@ class ShowRecipientsTest extends TestCase
|
|||
$this->actingAs($this->user);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_view_recipients_from_the_recipients_page()
|
||||
{
|
||||
Recipient::factory()->count(5)->create([
|
||||
|
@ -48,7 +46,7 @@ class ShowRecipientsTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function latest_recipients_are_listed_first()
|
||||
{
|
||||
$a = Recipient::factory()->create([
|
||||
|
@ -78,8 +76,8 @@ class ShowRecipientsTest extends TestCase
|
|||
$this->assertTrue($response->data('page')['props']['initialRows'][3]['id'] === $a->id);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
/* public function recipients_are_listed_with_aliases_count()
|
||||
/* #[Test]
|
||||
public function recipients_are_listed_with_aliases_count()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
'user_id' => $this->user->id,
|
||||
|
@ -100,7 +98,7 @@ class ShowRecipientsTest extends TestCase
|
|||
$this->assertCount(3, $response->data('recipients')[0]['aliases']);
|
||||
} */
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_resend_recipient_verification_email()
|
||||
{
|
||||
Notification::fake();
|
||||
|
@ -124,7 +122,7 @@ class ShowRecipientsTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_verify_recipient_email_successfully()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -152,7 +150,7 @@ class ShowRecipientsTest extends TestCase
|
|||
$this->assertNotNull($recipient->refresh()->email_verified_at);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_must_wait_before_resending_recipient_verification_email()
|
||||
{
|
||||
Notification::fake();
|
||||
|
|
|
@ -6,6 +6,7 @@ use App\Models\Username;
|
|||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Support\Carbon;
|
||||
use Inertia\Testing\AssertableInertia as Assert;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class ShowUsernamesTest extends TestCase
|
||||
|
@ -22,7 +23,7 @@ class ShowUsernamesTest extends TestCase
|
|||
$this->actingAs($this->user);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_view_usernames_from_the_usernames_page()
|
||||
{
|
||||
Username::factory()->count(3)->create([
|
||||
|
@ -40,7 +41,7 @@ class ShowUsernamesTest extends TestCase
|
|||
);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function latest_usernames_are_listed_first()
|
||||
{
|
||||
$a = Username::factory()->create([
|
||||
|
|
|
@ -12,14 +12,14 @@ use Ramsey\Uuid\Uuid;
|
|||
|
||||
abstract class TestCase extends BaseTestCase
|
||||
{
|
||||
use CreatesApplication;
|
||||
|
||||
protected $user;
|
||||
|
||||
protected function setUp(): void
|
||||
{
|
||||
parent::setUp();
|
||||
|
||||
$this->withoutVite();
|
||||
|
||||
config([
|
||||
'anonaddy.limit' => 1000,
|
||||
'anonaddy.additional_username_limit' => 3,
|
||||
|
|
|
@ -6,6 +6,7 @@ use App\Models\Alias;
|
|||
use App\Models\AliasRecipient;
|
||||
use App\Models\Recipient;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class AliasTest extends TestCase
|
||||
|
@ -21,7 +22,7 @@ class AliasTest extends TestCase
|
|||
$this->user = $this->createUser();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function alias_can_get_verified_recipients()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -52,7 +53,7 @@ class AliasTest extends TestCase
|
|||
$this->assertEquals($verifiedRecipient->id, $alias->verifiedRecipients[0]->id);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function alias_can_set_default_recipient_email()
|
||||
{
|
||||
Alias::factory()->create([
|
||||
|
@ -70,7 +71,7 @@ class AliasTest extends TestCase
|
|||
$this->assertEquals($this->user->default_recipient_id, $recipient->id);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function alias_can_get_default_recipient_email()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
@ -92,7 +93,7 @@ class AliasTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function alias_can_get_verified_recipients_or_default()
|
||||
{
|
||||
$alias = Alias::factory()->create([
|
||||
|
|
|
@ -6,6 +6,7 @@ use App\Mail\TokenExpiringSoon;
|
|||
use Carbon\Carbon;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use Illuminate\Support\Facades\Mail;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class EmailUsersWithTokenExpiringSoonTest extends TestCase
|
||||
|
@ -23,7 +24,7 @@ class EmailUsersWithTokenExpiringSoonTest extends TestCase
|
|||
Mail::fake();
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function it_can_send_a_mail_concerning_a_token_expiring_soon()
|
||||
{
|
||||
$this->setNow(2019, 1, 28);
|
||||
|
|
|
@ -6,6 +6,7 @@ use App\Models\Alias;
|
|||
use App\Models\AliasRecipient;
|
||||
use App\Models\Recipient;
|
||||
use Illuminate\Foundation\Testing\LazilyRefreshDatabase;
|
||||
use PHPUnit\Framework\Attributes\Test;
|
||||
use Tests\TestCase;
|
||||
|
||||
class UserTest extends TestCase
|
||||
|
@ -21,7 +22,7 @@ class UserTest extends TestCase
|
|||
$this->user = $this->createUser('johndoe');
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_aliases_from_relationship()
|
||||
{
|
||||
$aliases = Alias::factory()->count(10)->create([
|
||||
|
@ -31,7 +32,7 @@ class UserTest extends TestCase
|
|||
$aliases->assertEquals($this->user->aliases);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_only_get_their_own_aliases_from_relationship()
|
||||
{
|
||||
$aliases = Alias::factory()->count(5)->create([
|
||||
|
@ -43,7 +44,7 @@ class UserTest extends TestCase
|
|||
$aliases->assertEquals($this->user->aliases);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_total_emails_forwarded()
|
||||
{
|
||||
Alias::factory()->create([
|
||||
|
@ -66,7 +67,7 @@ class UserTest extends TestCase
|
|||
$this->assertEquals(10, $this->user->totalEmailsForwarded());
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_total_emails_blocked()
|
||||
{
|
||||
Alias::factory()->create([
|
||||
|
@ -89,7 +90,7 @@ class UserTest extends TestCase
|
|||
$this->assertEquals(8, $this->user->totalEmailsBlocked());
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_total_emails_replied()
|
||||
{
|
||||
Alias::factory()->create([
|
||||
|
@ -112,7 +113,7 @@ class UserTest extends TestCase
|
|||
$this->assertEquals(7, $this->user->totalEmailsReplied());
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_aliases_using_default_recipient()
|
||||
{
|
||||
$recipient = Recipient::factory()->create([
|
||||
|
@ -146,7 +147,7 @@ class UserTest extends TestCase
|
|||
$this->assertCount(3, $this->user->aliases);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_bandwidth_in_mb()
|
||||
{
|
||||
$this->user->update(['bandwidth' => 10485760]);
|
||||
|
@ -159,7 +160,7 @@ class UserTest extends TestCase
|
|||
$this->assertEquals(10, $this->user->bandwidth_mb);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_bandwidth_in_mb_to_correct_precision()
|
||||
{
|
||||
$this->user->update(['bandwidth' => 7324019]);
|
||||
|
@ -172,13 +173,13 @@ class UserTest extends TestCase
|
|||
$this->assertEquals(6.98, $this->user->bandwidth_mb);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_get_bandwidth_limit_in_mb()
|
||||
{
|
||||
$this->assertEquals(100, $this->user->getBandwidthLimitMb());
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_check_if_near_bandwidth_usage_limit()
|
||||
{
|
||||
$this->user->update(['bandwidth' => 100943820]);
|
||||
|
@ -193,7 +194,7 @@ class UserTest extends TestCase
|
|||
$this->assertEquals(96.27, $this->user->bandwidth_mb);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_get_domain_options()
|
||||
{
|
||||
$username = $this->user->username;
|
||||
|
@ -214,7 +215,7 @@ class UserTest extends TestCase
|
|||
});
|
||||
}
|
||||
|
||||
/** @test */
|
||||
#[Test]
|
||||
public function user_can_match_verified_recipient_with_extension()
|
||||
{
|
||||
$this->user->defaultRecipient->email = 'hello+anonaddy@example.com';
|
||||
|
|
|
@ -9,10 +9,10 @@ export default defineConfig(({ command, mode }) => {
|
|||
const host = env.APP_URL.replace(/https?:\/\//, '')
|
||||
return {
|
||||
server: {
|
||||
host: host,
|
||||
hmr: {
|
||||
host: host,
|
||||
},
|
||||
host: host,
|
||||
https: {
|
||||
key:
|
||||
process.env.NODE_ENV === 'production'
|
||||
|
@ -25,6 +25,7 @@ export default defineConfig(({ command, mode }) => {
|
|||
},
|
||||
watch: {
|
||||
usePolling: true,
|
||||
ignored: ['**/vendor/**', '**/postfix/**', '**/storage/**'],
|
||||
},
|
||||
},
|
||||
plugins: [
|
||||
|
@ -35,7 +36,6 @@ export default defineConfig(({ command, mode }) => {
|
|||
'resources/js/webauthn/authenticate.js',
|
||||
'resources/js/webauthn/register.js',
|
||||
],
|
||||
refresh: true,
|
||||
}),
|
||||
vue({
|
||||
template: {
|
||||
|
|
Loading…
Reference in a new issue