Resolve test load path

This commit is contained in:
djmaze 2026-10-27 01:33:48 +01:00
parent 650133ae8a
commit a827f8aded
5 changed files with 5 additions and 5 deletions

View file

@ -27,7 +27,7 @@ namespace RainLoop {
namespace {
// Enable SnappyMail Api and include index file
$_ENV['SNAPPYMAIL_INCLUDE_AS_API'] = true;
require '../index.php';
require __DIR__ . '/../index.php';
// define('APP_SALT', 'test-salt-'.bin2hex(random_bytes(8)));
$_COOKIE['smctoken'] = base64_encode(random_bytes(16));

View file

@ -3,7 +3,7 @@
// Run with: php test/header-injection.php
// Enable SnappyMail Api and include index file
$_ENV['SNAPPYMAIL_INCLUDE_AS_API'] = true;
require '../index.php';
require __DIR__ . '/../index.php';
function check(bool $condition, string $message): void
{

View file

@ -3,7 +3,7 @@
// Run with: php test/raw-inline-type.php
// Enable SnappyMail Api and include index file
$_ENV['SNAPPYMAIL_INCLUDE_AS_API'] = true;
require '../index.php';
require __DIR__ . '/../index.php';
function check(bool $condition, string $message): void
{

View file

@ -1,7 +1,7 @@
<?php
// Enable SnappyMail Api and include index file
$_ENV['SNAPPYMAIL_INCLUDE_AS_API'] = true;
require '../index.php';
require __DIR__ . '/../index.php';
function check(bool $condition, string $message): void
{

View file

@ -2,7 +2,7 @@
// Enable SnappyMail Api and include index file
$_ENV['SNAPPYMAIL_INCLUDE_AS_API'] = true;
require '../index.php';
require __DIR__ . '/../index.php';
/**
* Get SSO hash