Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .php_cs.dist
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ return PhpCsFixer\Config::create()
'import_constants' => true,
'import_functions' => false,
],
'native_constant_invocation' => true,
'native_function_invocation' => true,
'php_unit_test_case_static_method_calls' => [
'call_type' => 'this',
Expand Down
5 changes: 5 additions & 0 deletions src/PhpImap/DataPartInfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@

namespace PhpImap;

use const ENC8BIT;
use const ENCBASE64;
use const ENCBINARY;
use const ENCQUOTEDPRINTABLE;

/**
* @see https://github.com/barbushin/php-imap
*
Expand Down
1 change: 1 addition & 0 deletions src/PhpImap/Imap.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
use const IMAP_WRITETIMEOUT;
use InvalidArgumentException;
use const NIL;
use const SE_FREE;
use const SORTARRIVAL;
use const SORTCC;
use const SORTDATE;
Expand Down
1 change: 1 addition & 0 deletions src/PhpImap/IncomingMail.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

namespace PhpImap;

use const FILEINFO_MIME;
use InvalidArgumentException;

/**
Expand Down
33 changes: 33 additions & 0 deletions src/PhpImap/Mailbox.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,47 @@

namespace PhpImap;

use const CL_EXPUNGE;
use function count;
use const CP_UID;
use const DATE_RFC3339;
use DateTime;
use const DIRECTORY_SEPARATOR;
use Exception;
use const FILEINFO_EXTENSION;
use const FILEINFO_MIME;
use const FILEINFO_MIME_ENCODING;
use const FILEINFO_NONE;
use const FILEINFO_RAW;
use const FT_PEEK;
use const FT_PREFETCHTEXT;
use const FT_UID;
use const IMAP_CLOSETIMEOUT;
use const IMAP_OPENTIMEOUT;
use const IMAP_READTIMEOUT;
use const IMAP_WRITETIMEOUT;
use InvalidArgumentException;
use const OP_ANONYMOUS;
use const OP_DEBUG;
use const OP_HALFOPEN;
use const OP_PROTOTYPE;
use const OP_READONLY;
use const OP_SECURE;
use const OP_SHORTCACHE;
use const OP_SILENT;
use const PATHINFO_EXTENSION;
use PhpImap\Exceptions\ConnectionException;
use PhpImap\Exceptions\InvalidParameterException;
use const SA_ALL;
use const SE_FREE;
use const SE_UID;
use const SORT_NUMERIC;
use const SORTARRIVAL;
use const ST_UID;
use stdClass;
use const TYPEMESSAGE;
use const TYPEMULTIPART;
use const TYPETEXT;
use UnexpectedValueException;

/**
Expand Down
2 changes: 2 additions & 0 deletions tests/unit/IncomingMailTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@

namespace PhpImap;

use const DATE_RFC3339;
use const ENCOTHER;
use PHPUnit\Framework\TestCase;

class IncomingMailTest extends TestCase
Expand Down
1 change: 1 addition & 0 deletions tests/unit/LiveMailboxIssue490Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@

use Exception;
use ParagonIE\HiddenString\HiddenString;
use const TYPEMULTIPART;
use const TYPETEXT;

/**
Expand Down
4 changes: 4 additions & 0 deletions tests/unit/LiveMailboxTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,13 @@
namespace PhpImap;

use function date;
use const ENCBASE64;
use Exception;
use Generator;
use ParagonIE\HiddenString\HiddenString;
use const SORTARRIVAL;
use const TYPEAPPLICATION;
use const TYPEMULTIPART;
use const TYPETEXT;

/**
Expand Down
15 changes: 15 additions & 0 deletions tests/unit/MailboxTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,24 @@

namespace PhpImap;

use const CL_EXPUNGE;
use DateTime;
use const IMAP_CLOSETIMEOUT;
use const IMAP_OPENTIMEOUT;
use const IMAP_READTIMEOUT;
use const IMAP_WRITETIMEOUT;
use const OP_ANONYMOUS;
use const OP_DEBUG;
use const OP_HALFOPEN;
use const OP_PROTOTYPE;
use const OP_READONLY;
use const OP_SECURE;
use const OP_SHORTCACHE;
use const OP_SILENT;
use PhpImap\Exceptions\InvalidParameterException;
use PHPUnit\Framework\TestCase;
use const SE_FREE;
use const SE_UID;

final class MailboxTest extends TestCase
{
Expand Down