From 6ef786ac96fcd4cbfff0dca41bdc4c14cc20d9fb Mon Sep 17 00:00:00 2001 From: Ryan Parman Date: Wed, 29 Nov 2017 20:34:36 -0800 Subject: [PATCH] Fixed the copyright headers. --- .gitignore | 1 + .php_cs.dist | 263 ++++++- composer.lock | 862 ++++++++++++--------- src/Bytes.php | 203 +++++ src/QueryString.php | 10 +- src/Time.php | 8 +- src/Types.php | 12 +- src/Url.php | 12 +- tests/Unit/AbstractTestCase.php | 7 +- tests/Unit/UtilityPack/BytesTest.php | 142 ++++ tests/Unit/UtilityPack/QueryStringTest.php | 12 +- tests/Unit/UtilityPack/TimeTest.php | 16 +- tests/Unit/UtilityPack/TypeTest.php | 12 +- tests/Unit/UtilityPack/UrlTest.php | 78 +- tests/bootstrap.php | 13 +- 15 files changed, 1175 insertions(+), 476 deletions(-) create mode 100644 src/Bytes.php create mode 100644 tests/Unit/UtilityPack/BytesTest.php diff --git a/.gitignore b/.gitignore index f321844..9fdaead 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ .DS_Store +.php_cs.cache .phpintel/ bin/ reports/ diff --git a/.php_cs.dist b/.php_cs.dist index 496f1b9..868e983 100644 --- a/.php_cs.dist +++ b/.php_cs.dist @@ -1,7 +1,8 @@ . + * + * Rules current as of https://github.com/FriendsOfPHP/PHP-CS-Fixer/blob/v2.8.0/README.rst */ use PhpCsFixer\Config; @@ -12,58 +13,254 @@ $finder = PhpCsFixer\Finder::create() ->in(__DIR__ . '/tests') ; +$fileHeader = <<<'EOF' +Copyright (c) 2010-2017 Ryan Parman +Copyright (c) 2016-2017 Lucky Rocketship Underpants, LLC. +EOF; + return Config::create() ->setIndent(" ") ->setLineEnding("\n") ->setRiskyAllowed(true) ->setRules([ // Configurable + 'align_multiline_comment' => [ + 'comment_type' => 'all_multiline', + ], 'array_syntax' => [ 'syntax' => 'short', ], 'binary_operator_spaces'=> [ - 'align_double_arrow' => true, - 'align_equals' => true, + 'default' => 'align_single_space_minimal', + 'operators' => [ + '=' => 'align_single_space_minimal', + '=>' => 'align_single_space_minimal', + ], + ], + 'blank_line_before_statement' => [ + 'statements' => [ + 'break', + 'continue', + 'declare', + 'do', + 'for', + 'foreach', + 'if', + 'return', + 'throw', + 'try', + 'while', + ], + ], + 'braces' => [ + 'allow_single_line_closure' => false, + 'position_after_anonymous_constructs' => 'same', + 'position_after_control_structures' => 'same', + 'position_after_functions_and_oop_constructs' => 'next', + ], + 'cast_spaces' => [ + 'space' => 'single', + ], + 'class_definition' => [ + 'multiLineExtendsEachSingleLine' => false, + 'singleItemSingleLine' => true, + 'singleLine' => true, ], 'concat_space' => [ 'spacing' => 'one', ], + 'declare_equal_normalize' => [ + 'space' => 'none', + ], + 'function_declaration' => [ + 'closure_function_spacing' => 'one', + ], + 'function_to_constant' => [ + 'functions' => [ + 'get_class', + 'phpversion', + 'php_sapi_name', + 'pi', + ], + ], + 'general_phpdoc_annotation_remove' => [ + 'annotations' => [ + 'author', + 'package', + 'subpackage', + ], + ], + 'header_comment' => [ + 'commentType' => 'PHPDoc', + 'location' => 'after_open', + 'separate' => 'bottom', + 'header' => $fileHeader, + ], + 'increment_style' => [ + 'style' => 'post', + ], + 'is_null' => [ + 'use_yoda_style' => true, + ], + 'list_syntax' => [ + 'syntax' => 'short', + ], + 'method_argument_space' => [ + 'ensure_fully_multiline' => true, + 'keep_multiple_spaces_after_comma' => false, + ], + 'no_break_comment' => [ + 'comment_text' => 'no break', + ], + 'no_extra_consecutive_blank_lines' => [ + 'tokens' => [ + 'use', + ], + ], 'no_mixed_echo_print' => [ 'use' => 'echo', ], + 'no_spaces_around_offset' => [ + 'positions' => [ + 'inside', + 'outside' + ], + ], + 'no_unneeded_control_parentheses' => [ + 'statements' => [ + 'break', + 'clone', + 'continue', + 'echo_print', + 'return', + 'switch_case', + 'yield', + ], + ], + 'non_printable_character' => [ + 'use_escape_sequences_in_strings' => false, + ], + 'ordered_class_elements' => [ + 'order' => [ + 'use_trait', + 'constant_public', + 'constant_protected', + 'constant_private', + 'property_public', + 'property_protected', + 'property_private', + 'construct', + 'destruct', + 'magic', + 'phpunit', + 'method_public', + 'method_protected', + 'method_private', + ], + ], + 'ordered_imports' => [ + 'importsOrder' => null, + 'sortAlgorithm' => 'alpha', + ], + 'php_unit_construct' => [ + 'assertions' => [ + 'assertEquals', + 'assertSame', + 'assertNotEquals', + 'assertNotSame', + ], + ], + 'php_unit_dedicate_assert' => [ + 'target' => 'newest', + ], + 'php_unit_expectation' => [ + 'target' => 'newest', + ], + 'php_unit_no_expectation_annotation' => [ + 'target' => 'newest', + 'use_class_const' => true, + ], 'phpdoc_no_alias_tag' => [ 'property-read' => 'property', 'property-write' => 'property', 'type' => 'var', + 'link' => 'see', + ], + 'phpdoc_add_missing_param_annotation' => [ + 'only_untyped' => false, + ], + 'phpdoc_align' => [ + 'tags' => [ + 'param', + 'return', + 'throws', + 'type', + 'var', + ], + ], + 'phpdoc_return_self_reference' => [ + 'replacements' => [ + 'this' => '$this', + '@this' => '$this', + '$self' => 'self', + '@self' => 'self', + '$static' => 'static', + '@static' => 'static', + ], + ], + 'phpdoc_types_order' => [ + 'null_adjustment' => 'always_last', ], 'random_api_migration' => [ - 'mt_rand' => 'random_int', - 'rand' => 'random_int', + 'replacements' => [ + 'getrandmax' => 'mt_getrandmax', + 'mt_rand' => 'random_int', + 'rand' => 'random_int', + 'srand' => 'random_int', + ], + ], + 'return_type_declaration' => [ + 'space_before' => 'none', + ], + 'single_class_element_per_statement' => [ + 'elements' => [ + 'const', + 'property', + ], + ], + 'single_line_comment_style' => [ + 'comment_types' => [ + 'hash', + ], + ], + 'space_after_semicolon' => [ + 'remove_in_empty_for_expressions' => false, ], 'visibility_required' => [ 'const', 'method', 'property', ], - 'no_extra_consecutive_blank_lines' => ['use'], + 'yoda_style' => [ + 'equal' => true, + 'identical' => true, + 'less_and_greater' => false, + ], // Enforce 'blank_line_after_namespace' => true, 'blank_line_after_opening_tag' => true, - 'blank_line_before_return' => true, - 'braces' => true, - 'cast_spaces' => true, - 'class_definition' => true, + 'combine_consecutive_issets' => true, 'combine_consecutive_unsets' => true, - 'declare_equal_normalize' => true, + 'compact_nullable_typehint' => true, 'declare_strict_types' => true, 'dir_constant' => true, 'elseif' => true, 'encoding' => true, + 'ereg_to_preg' => true, 'full_opening_tag' => true, - 'function_declaration' => true, 'function_typehint_space' => true, - 'hash_to_slash_comment' => true, + 'heredoc_to_nowdoc' => true, 'include' => true, 'indentation_type' => true, 'line_ending' => true, @@ -71,11 +268,12 @@ return Config::create() 'lowercase_cast' => true, 'lowercase_constants' => true, 'lowercase_keywords' => true, + 'magic_constant_casing' => true, 'mb_str_functions' => true, - 'method_argument_space' => true, 'method_separation' => true, 'modernize_types_casting' => true, 'native_function_casing' => true, + 'native_function_invocation' => true, 'new_with_braces' => true, 'no_alias_functions' => true, 'no_blank_lines_after_class_opening' => true, @@ -84,21 +282,24 @@ return Config::create() 'no_empty_comment' => true, 'no_empty_phpdoc' => true, 'no_empty_statement' => true, + 'no_homoglyph_names' => true, 'no_leading_import_slash' => true, 'no_leading_namespace_whitespace' => true, 'no_multiline_whitespace_around_double_arrow' => true, 'no_multiline_whitespace_before_semicolons' => true, + 'no_null_property_initialization' => true, 'no_php4_constructor' => true, 'no_short_bool_cast' => true, 'no_singleline_whitespace_before_semicolons' => true, 'no_spaces_after_function_name' => true, - 'no_spaces_around_offset' => true, 'no_spaces_inside_parenthesis' => true, + 'no_superfluous_elseif' => true, 'no_trailing_comma_in_list_call' => true, 'no_trailing_comma_in_singleline_array' => true, 'no_trailing_whitespace' => true, 'no_trailing_whitespace_in_comment' => true, - 'no_unneeded_control_parentheses' => true, + 'no_unneeded_curly_braces' => true, + 'no_unneeded_final_method' => true, 'no_unreachable_default_argument_value' => true, 'no_unused_imports' => true, 'no_useless_else' => true, @@ -107,17 +308,15 @@ return Config::create() 'no_whitespace_in_blank_line' => true, 'normalize_index_brace' => true, 'object_operator_without_whitespace' => true, - 'ordered_imports' => true, - 'php_unit_construct' => true, - 'php_unit_dedicate_assert' => true, 'php_unit_fqcn_annotation' => true, - 'phpdoc_add_missing_param_annotation' => true, - 'phpdoc_align' => true, + 'php_unit_mock' => true, + 'php_unit_test_class_requires_covers' => true, 'phpdoc_indent' => true, 'phpdoc_inline_tag' => true, 'phpdoc_no_access' => true, 'phpdoc_no_empty_return' => true, 'phpdoc_no_package' => true, + 'phpdoc_no_useless_inheritdoc' => true, 'phpdoc_order' => true, 'phpdoc_scalar' => true, 'phpdoc_separation' => true, @@ -129,50 +328,44 @@ return Config::create() 'phpdoc_var_without_name' => true, 'pow_to_exponentiation' => true, 'psr4' => true, - 'return_type_declaration' => true, 'self_accessor' => true, 'semicolon_after_instruction' => true, 'short_scalar_cast' => true, + 'simplified_null_return' => true, 'single_blank_line_at_eof' => true, 'single_blank_line_before_namespace' => true, - 'single_class_element_per_statement' => true, 'single_import_per_statement' => true, 'single_line_after_imports' => true, 'single_quote' => true, - 'space_after_semicolon' => true, 'standardize_not_equals' => true, 'strict_comparison' => true, 'strict_param' => true, 'switch_case_semicolon_to_colon' => true, 'switch_case_space' => true, 'ternary_operator_spaces' => true, + 'ternary_to_null_coalescing' => true, 'trailing_comma_in_multiline_array' => true, 'trim_array_spaces' => true, 'unary_operator_spaces' => true, + 'void_return' => true, 'whitespace_after_comma_in_array' => true, // Do not enforce 'class_keyword_remove' => false, - 'ereg_to_preg' => false, - 'heredoc_to_nowdoc' => false, + 'doctrine_annotation_braces' => false, + 'doctrine_annotation_indentation' => false, + 'doctrine_annotation_spaces' => false, 'no_blank_lines_before_namespace' => false, 'no_short_echo_tag' => false, 'not_operator_with_space' => false, 'not_operator_with_successor_space' => false, - 'not_operator_with_successor_space' => false, - 'ordered_class_elements' => false, + 'php_unit_namespaced' => false, 'php_unit_strict' => false, 'phpdoc_annotation_without_dot' => false, - 'pre_increment' => false, 'protected_to_private' => false, 'psr0' => false, 'silenced_deprecation_error' => false, - 'simplified_null_return' => false, - - // Unused - // 'header_comment' => ['header' => ''] - ]) ->setFinder($finder) - ->setUsingCache(false) + ->setUsingCache(true) ; diff --git a/composer.lock b/composer.lock index a2acedf..5911bad 100644 --- a/composer.lock +++ b/composer.lock @@ -58,6 +58,68 @@ } ], "packages-dev": [ + { + "name": "composer/semver", + "version": "1.4.2", + "source": { + "type": "git", + "url": "https://github.com/composer/semver.git", + "reference": "c7cb9a2095a074d131b65a8a0cd294479d785573" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/semver/zipball/c7cb9a2095a074d131b65a8a0cd294479d785573", + "reference": "c7cb9a2095a074d131b65a8a0cd294479d785573", + "shasum": "" + }, + "require": { + "php": "^5.3.2 || ^7.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.5 || ^5.0.5", + "phpunit/phpunit-mock-objects": "2.3.0 || ^3.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Composer\\Semver\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nils Adermann", + "email": "naderman@naderman.de", + "homepage": "http://www.naderman.de" + }, + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + }, + { + "name": "Rob Bast", + "email": "rob.bast@gmail.com", + "homepage": "http://robbast.nl" + } + ], + "description": "Semver library that offers utilities, version constraint parsing and validation.", + "keywords": [ + "semantic", + "semver", + "validation", + "versioning" + ], + "time": "2016-08-30T16:08:34+00:00" + }, { "name": "container-interop/container-interop", "version": "1.2.0", @@ -137,21 +199,21 @@ }, { "name": "doctrine/annotations", - "version": "v1.4.0", + "version": "v1.5.0", "source": { "type": "git", "url": "https://github.com/doctrine/annotations.git", - "reference": "54cacc9b81758b14e3ce750f205a393d52339e97" + "reference": "5beebb01b025c94e93686b7a0ed3edae81fe3e7f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/annotations/zipball/54cacc9b81758b14e3ce750f205a393d52339e97", - "reference": "54cacc9b81758b14e3ce750f205a393d52339e97", + "url": "https://api.github.com/repos/doctrine/annotations/zipball/5beebb01b025c94e93686b7a0ed3edae81fe3e7f", + "reference": "5beebb01b025c94e93686b7a0ed3edae81fe3e7f", "shasum": "" }, "require": { "doctrine/lexer": "1.*", - "php": "^5.6 || ^7.0" + "php": "^7.1" }, "require-dev": { "doctrine/cache": "1.*", @@ -160,7 +222,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4.x-dev" + "dev-master": "1.5.x-dev" } }, "autoload": { @@ -201,36 +263,36 @@ "docblock", "parser" ], - "time": "2017-02-24T16:22:25+00:00" + "time": "2017-07-22T10:58:02+00:00" }, { "name": "doctrine/instantiator", - "version": "1.0.5", + "version": "1.1.0", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d" + "reference": "185b8868aa9bf7159f5f953ed5afb2d7fcdc3bda" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/8e884e78f9f0eb1329e445619e04456e64d8051d", - "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/185b8868aa9bf7159f5f953ed5afb2d7fcdc3bda", + "reference": "185b8868aa9bf7159f5f953ed5afb2d7fcdc3bda", "shasum": "" }, "require": { - "php": ">=5.3,<8.0-DEV" + "php": "^7.1" }, "require-dev": { "athletic/athletic": "~0.1.8", "ext-pdo": "*", "ext-phar": "*", - "phpunit/phpunit": "~4.0", - "squizlabs/php_codesniffer": "~2.0" + "phpunit/phpunit": "^6.2.3", + "squizlabs/php_codesniffer": "^3.0.2" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.2.x-dev" } }, "autoload": { @@ -255,7 +317,7 @@ "constructor", "instantiate" ], - "time": "2015-06-14T21:17:01+00:00" + "time": "2017-07-22T11:58:36+00:00" }, { "name": "doctrine/lexer", @@ -313,65 +375,66 @@ }, { "name": "friendsofphp/php-cs-fixer", - "version": "v2.3.2", + "version": "v2.8.3", "source": { "type": "git", "url": "https://github.com/FriendsOfPHP/PHP-CS-Fixer.git", - "reference": "597745f744bcce1aed59dfd1bb4603de2a06cda9" + "reference": "d9ec9b848cbf930c31dea3693d34dbd8b9c95295" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/597745f744bcce1aed59dfd1bb4603de2a06cda9", - "reference": "597745f744bcce1aed59dfd1bb4603de2a06cda9", + "url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/d9ec9b848cbf930c31dea3693d34dbd8b9c95295", + "reference": "d9ec9b848cbf930c31dea3693d34dbd8b9c95295", "shasum": "" }, "require": { + "composer/semver": "^1.4", "doctrine/annotations": "^1.2", "ext-json": "*", "ext-tokenizer": "*", - "gecko-packages/gecko-php-unit": "^2.0", - "php": "^5.6 || >=7.0 <7.2", - "sebastian/diff": "^1.4", - "symfony/console": "^3.0", - "symfony/event-dispatcher": "^3.0", - "symfony/filesystem": "^3.0", - "symfony/finder": "^3.0", - "symfony/options-resolver": "^3.0", + "gecko-packages/gecko-php-unit": "^2.0 || ^3.0", + "php": "^5.6 || >=7.0 <7.3", + "php-cs-fixer/diff": "^1.2", + "symfony/console": "^3.2 || ^4.0", + "symfony/event-dispatcher": "^3.0 || ^4.0", + "symfony/filesystem": "^3.0 || ^4.0", + "symfony/finder": "^3.0 || ^4.0", + "symfony/options-resolver": "^3.0 || ^4.0", "symfony/polyfill-php70": "^1.0", - "symfony/polyfill-xml": "^1.3", - "symfony/process": "^3.0", - "symfony/stopwatch": "^3.0" + "symfony/polyfill-php72": "^1.4", + "symfony/process": "^3.0 || ^4.0", + "symfony/stopwatch": "^3.0 || ^4.0" }, "conflict": { - "hhvm": "<3.18" + "hhvm": "*" }, "require-dev": { - "johnkary/phpunit-speedtrap": "^1.1", + "johnkary/phpunit-speedtrap": "^1.1 || ^2.0@dev", "justinrainbow/json-schema": "^5.0", - "mi-schi/phpmd-extension": "^4.2", - "phpmd/phpmd": "^2.4.3", - "phpunit/phpunit": "^4.8.35 || ^5.4.3", - "satooshi/php-coveralls": "^1.0", - "symfony/phpunit-bridge": "^3.2.2" + "php-coveralls/php-coveralls": "^1.0.2", + "php-cs-fixer/accessible-object": "^1.0", + "phpunit/phpunit": "^5.7.23 || ^6.4.3", + "symfony/phpunit-bridge": "^3.2.2 || ^4.0" }, "suggest": { "ext-mbstring": "For handling non-UTF8 characters in cache signature.", - "ext-xml": "For better performance.", "symfony/polyfill-mbstring": "When enabling `ext-mbstring` is not possible." }, "bin": [ "php-cs-fixer" ], "type": "application", - "extra": { - "branch-alias": { - "dev-master": "2.3-dev" - } - }, "autoload": { "psr-4": { "PhpCsFixer\\": "src/" - } + }, + "classmap": [ + "tests/Test/Assert/AssertTokensTrait.php", + "tests/Test/AbstractFixerTestCase.php", + "tests/Test/AbstractIntegrationTestCase.php", + "tests/Test/IntegrationCase.php", + "tests/Test/IntegrationCaseFactory.php" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -388,46 +451,56 @@ } ], "description": "A tool to automatically fix PHP code style", - "time": "2017-05-24T21:59:38+00:00" + "time": "2017-11-26T20:45:16+00:00" }, { "name": "gecko-packages/gecko-php-unit", - "version": "v2.0", + "version": "v3.0", "source": { "type": "git", "url": "https://github.com/GeckoPackages/GeckoPHPUnit.git", - "reference": "40a697ec261f3526e8196363b481b24383740c13" + "reference": "6a866551dffc2154c1b091bae3a7877d39c25ca3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/GeckoPackages/GeckoPHPUnit/zipball/40a697ec261f3526e8196363b481b24383740c13", - "reference": "40a697ec261f3526e8196363b481b24383740c13", + "url": "https://api.github.com/repos/GeckoPackages/GeckoPHPUnit/zipball/6a866551dffc2154c1b091bae3a7877d39c25ca3", + "reference": "6a866551dffc2154c1b091bae3a7877d39c25ca3", "shasum": "" }, "require": { - "php": "^5.3.6 || ^7.0" + "php": "^7.0" }, "require-dev": { - "phpunit/phpunit": "4.0" + "phpunit/phpunit": "^6.0" + }, + "suggest": { + "ext-dom": "When testing with xml.", + "ext-libxml": "When testing with xml.", + "phpunit/phpunit": "This is an extension for it so make sure you have it some way." }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" + } + }, "autoload": { "psr-4": { - "GeckoPackages\\PHPUnit\\": "src\\PHPUnit" + "GeckoPackages\\PHPUnit\\": "src/PHPUnit" } }, "notification-url": "https://packagist.org/downloads/", "license": [ "MIT" ], - "description": "Additional PHPUnit tests.", + "description": "Additional PHPUnit asserts and constraints.", "homepage": "https://github.com/GeckoPackages", "keywords": [ "extension", "filesystem", "phpunit" ], - "time": "2016-11-22T11:01:27+00:00" + "time": "2017-08-23T07:46:41+00:00" }, { "name": "kore/data-object", @@ -465,37 +538,40 @@ }, { "name": "myclabs/deep-copy", - "version": "1.6.1", + "version": "1.7.0", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "8e6e04167378abf1ddb4d3522d8755c5fd90d102" + "reference": "3b8a3a99ba1f6a3952ac2747d989303cbd6b7a3e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/8e6e04167378abf1ddb4d3522d8755c5fd90d102", - "reference": "8e6e04167378abf1ddb4d3522d8755c5fd90d102", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/3b8a3a99ba1f6a3952ac2747d989303cbd6b7a3e", + "reference": "3b8a3a99ba1f6a3952ac2747d989303cbd6b7a3e", "shasum": "" }, "require": { - "php": ">=5.4.0" + "php": "^5.6 || ^7.0" }, "require-dev": { - "doctrine/collections": "1.*", - "phpunit/phpunit": "~4.1" + "doctrine/collections": "^1.0", + "doctrine/common": "^2.6", + "phpunit/phpunit": "^4.1" }, "type": "library", "autoload": { "psr-4": { "DeepCopy\\": "src/DeepCopy/" - } + }, + "files": [ + "src/DeepCopy/deep_copy.php" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ "MIT" ], "description": "Create deep copies (clones) of your objects", - "homepage": "https://github.com/myclabs/DeepCopy", "keywords": [ "clone", "copy", @@ -503,7 +579,7 @@ "object", "object graph" ], - "time": "2017-04-12T18:52:22+00:00" + "time": "2017-10-19T19:58:43+00:00" }, { "name": "nikic/fast-route", @@ -550,16 +626,16 @@ }, { "name": "nikic/php-parser", - "version": "v3.0.5", + "version": "v3.1.2", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "2b9e2f71b722f7c53918ab0c25f7646c2013f17d" + "reference": "08131e7ff29de6bb9f12275c7d35df71f25f4d89" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/2b9e2f71b722f7c53918ab0c25f7646c2013f17d", - "reference": "2b9e2f71b722f7c53918ab0c25f7646c2013f17d", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/08131e7ff29de6bb9f12275c7d35df71f25f4d89", + "reference": "08131e7ff29de6bb9f12275c7d35df71f25f4d89", "shasum": "" }, "require": { @@ -597,20 +673,20 @@ "parser", "php" ], - "time": "2017-03-05T18:23:57+00:00" + "time": "2017-11-04T11:48:34+00:00" }, { "name": "paragonie/random_compat", - "version": "v2.0.10", + "version": "v2.0.11", "source": { "type": "git", "url": "https://github.com/paragonie/random_compat.git", - "reference": "634bae8e911eefa89c1abfbf1b66da679ac8f54d" + "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/paragonie/random_compat/zipball/634bae8e911eefa89c1abfbf1b66da679ac8f54d", - "reference": "634bae8e911eefa89c1abfbf1b66da679ac8f54d", + "url": "https://api.github.com/repos/paragonie/random_compat/zipball/5da4d3c796c275c55f057af5a643ae297d96b4d8", + "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8", "shasum": "" }, "require": { @@ -645,7 +721,7 @@ "pseudorandom", "random" ], - "time": "2017-03-13T16:27:32+00:00" + "time": "2017-09-27T21:40:39+00:00" }, { "name": "pdepend/pdepend", @@ -789,18 +865,66 @@ "description": "Library for handling version information and constraints", "time": "2017-03-05T17:38:23+00:00" }, + { + "name": "php-cs-fixer/diff", + "version": "v1.2.0", + "source": { + "type": "git", + "url": "https://github.com/PHP-CS-Fixer/diff.git", + "reference": "f0ef6133d674137e902fdf8a6f2e8e97e14a087b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/PHP-CS-Fixer/diff/zipball/f0ef6133d674137e902fdf8a6f2e8e97e14a087b", + "reference": "f0ef6133d674137e902fdf8a6f2e8e97e14a087b", + "shasum": "" + }, + "require": { + "php": "^5.6 || ^7.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.8.35 || ^5.4.3", + "symfony/process": "^3.3" + }, + "type": "library", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "authors": [ + { + "name": "Kore Nordmann", + "email": "mail@kore-nordmann.de" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "SpacePossum" + } + ], + "description": "sebastian/diff v2 backport support for PHP5.6", + "homepage": "https://github.com/PHP-CS-Fixer", + "keywords": [ + "diff" + ], + "time": "2017-10-19T09:58:18+00:00" + }, { "name": "phpdocumentor/reflection-common", - "version": "1.0", + "version": "1.0.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionCommon.git", - "reference": "144c307535e82c8fdcaacbcfc1d6d8eeb896687c" + "reference": "21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/144c307535e82c8fdcaacbcfc1d6d8eeb896687c", - "reference": "144c307535e82c8fdcaacbcfc1d6d8eeb896687c", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6", + "reference": "21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6", "shasum": "" }, "require": { @@ -841,33 +965,39 @@ "reflection", "static analysis" ], - "time": "2015-12-27T11:43:31+00:00" + "time": "2017-09-11T18:02:19+00:00" }, { "name": "phpdocumentor/reflection-docblock", - "version": "3.1.1", + "version": "4.2.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "8331b5efe816ae05461b7ca1e721c01b46bafb3e" + "reference": "66465776cfc249844bde6d117abff1d22e06c2da" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/8331b5efe816ae05461b7ca1e721c01b46bafb3e", - "reference": "8331b5efe816ae05461b7ca1e721c01b46bafb3e", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/66465776cfc249844bde6d117abff1d22e06c2da", + "reference": "66465776cfc249844bde6d117abff1d22e06c2da", "shasum": "" }, "require": { - "php": ">=5.5", - "phpdocumentor/reflection-common": "^1.0@dev", - "phpdocumentor/type-resolver": "^0.2.0", + "php": "^7.0", + "phpdocumentor/reflection-common": "^1.0.0", + "phpdocumentor/type-resolver": "^0.4.0", "webmozart/assert": "^1.0" }, "require-dev": { - "mockery/mockery": "^0.9.4", - "phpunit/phpunit": "^4.4" + "doctrine/instantiator": "~1.0.5", + "mockery/mockery": "^1.0", + "phpunit/phpunit": "^6.4" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.x-dev" + } + }, "autoload": { "psr-4": { "phpDocumentor\\Reflection\\": [ @@ -886,24 +1016,24 @@ } ], "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", - "time": "2016-09-30T07:12:33+00:00" + "time": "2017-11-27T17:38:31+00:00" }, { "name": "phpdocumentor/type-resolver", - "version": "0.2.1", + "version": "0.4.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb" + "reference": "9c977708995954784726e25d0cd1dddf4e65b0f7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb", - "reference": "e224fb2ea2fba6d3ad6fdaef91cd09a172155ccb", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/9c977708995954784726e25d0cd1dddf4e65b0f7", + "reference": "9c977708995954784726e25d0cd1dddf4e65b0f7", "shasum": "" }, "require": { - "php": ">=5.5", + "php": "^5.5 || ^7.0", "phpdocumentor/reflection-common": "^1.0" }, "require-dev": { @@ -933,7 +1063,7 @@ "email": "me@mikevanriel.com" } ], - "time": "2016-11-25T06:54:22+00:00" + "time": "2017-07-14T14:27:02+00:00" }, { "name": "phploc/phploc", @@ -1056,16 +1186,16 @@ }, { "name": "phpmetrics/phpmetrics", - "version": "v2.2.0", + "version": "v2.3.2", "source": { "type": "git", "url": "https://github.com/phpmetrics/PhpMetrics.git", - "reference": "cc553d9ede844cd638e0d208b4f6eb6a201d2bbd" + "reference": "e44f5224d08571ee6ba85c50379560b9ec217b91" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpmetrics/PhpMetrics/zipball/cc553d9ede844cd638e0d208b4f6eb6a201d2bbd", - "reference": "cc553d9ede844cd638e0d208b4f6eb6a201d2bbd", + "url": "https://api.github.com/repos/phpmetrics/PhpMetrics/zipball/e44f5224d08571ee6ba85c50379560b9ec217b91", + "reference": "e44f5224d08571ee6ba85c50379560b9ec217b91", "shasum": "" }, "require": { @@ -1113,37 +1243,37 @@ "quality", "testing" ], - "time": "2017-04-13T05:18:28+00:00" + "time": "2017-10-13T16:11:30+00:00" }, { "name": "phpspec/prophecy", - "version": "v1.7.0", + "version": "1.7.3", "source": { "type": "git", "url": "https://github.com/phpspec/prophecy.git", - "reference": "93d39f1f7f9326d746203c7c056f300f7f126073" + "reference": "e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/93d39f1f7f9326d746203c7c056f300f7f126073", - "reference": "93d39f1f7f9326d746203c7c056f300f7f126073", + "url": "https://api.github.com/repos/phpspec/prophecy/zipball/e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf", + "reference": "e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf", "shasum": "" }, "require": { "doctrine/instantiator": "^1.0.2", "php": "^5.3|^7.0", - "phpdocumentor/reflection-docblock": "^2.0|^3.0.2", + "phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0", "sebastian/comparator": "^1.1|^2.0", "sebastian/recursion-context": "^1.0|^2.0|^3.0" }, "require-dev": { "phpspec/phpspec": "^2.5|^3.2", - "phpunit/phpunit": "^4.8 || ^5.6.5" + "phpunit/phpunit": "^4.8.35 || ^5.7" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.6.x-dev" + "dev-master": "1.7.x-dev" } }, "autoload": { @@ -1176,32 +1306,32 @@ "spy", "stub" ], - "time": "2017-03-02T20:05:34+00:00" + "time": "2017-11-24T13:59:53+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "5.2.1", + "version": "5.2.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "dc421f9ca5082a0c0cb04afb171c765f79add85b" + "reference": "033ec97498cf530cc1be4199264cad568b19be26" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/dc421f9ca5082a0c0cb04afb171c765f79add85b", - "reference": "dc421f9ca5082a0c0cb04afb171c765f79add85b", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/033ec97498cf530cc1be4199264cad568b19be26", + "reference": "033ec97498cf530cc1be4199264cad568b19be26", "shasum": "" }, "require": { "ext-dom": "*", "ext-xmlwriter": "*", "php": "^7.0", - "phpunit/php-file-iterator": "^1.3", - "phpunit/php-text-template": "^1.2", - "phpunit/php-token-stream": "^1.4.11 || ^2.0", - "sebastian/code-unit-reverse-lookup": "^1.0", + "phpunit/php-file-iterator": "^1.4.2", + "phpunit/php-text-template": "^1.2.1", + "phpunit/php-token-stream": "^2.0.1", + "sebastian/code-unit-reverse-lookup": "^1.0.1", "sebastian/environment": "^3.0", - "sebastian/version": "^2.0", + "sebastian/version": "^2.0.1", "theseer/tokenizer": "^1.1" }, "require-dev": { @@ -1209,7 +1339,7 @@ "phpunit/phpunit": "^6.0" }, "suggest": { - "ext-xdebug": "^2.5.3" + "ext-xdebug": "^2.5.5" }, "type": "library", "extra": { @@ -1240,20 +1370,20 @@ "testing", "xunit" ], - "time": "2017-04-21T08:03:57+00:00" + "time": "2017-11-27T09:00:30+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "1.4.2", + "version": "1.4.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "3cc8f69b3028d0f96a9078e6295d86e9bf019be5" + "reference": "730b01bc3e867237eaac355e06a36b85dd93a8b4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/3cc8f69b3028d0f96a9078e6295d86e9bf019be5", - "reference": "3cc8f69b3028d0f96a9078e6295d86e9bf019be5", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/730b01bc3e867237eaac355e06a36b85dd93a8b4", + "reference": "730b01bc3e867237eaac355e06a36b85dd93a8b4", "shasum": "" }, "require": { @@ -1287,7 +1417,7 @@ "filesystem", "iterator" ], - "time": "2016-10-03T07:40:28+00:00" + "time": "2017-11-27T13:52:08+00:00" }, { "name": "phpunit/php-text-template", @@ -1381,29 +1511,29 @@ }, { "name": "phpunit/php-token-stream", - "version": "1.4.11", + "version": "2.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "e03f8f67534427a787e21a385a67ec3ca6978ea7" + "reference": "791198a2c6254db10131eecfe8c06670700904db" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/e03f8f67534427a787e21a385a67ec3ca6978ea7", - "reference": "e03f8f67534427a787e21a385a67ec3ca6978ea7", + "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/791198a2c6254db10131eecfe8c06670700904db", + "reference": "791198a2c6254db10131eecfe8c06670700904db", "shasum": "" }, "require": { "ext-tokenizer": "*", - "php": ">=5.3.3" + "php": "^7.0" }, "require-dev": { - "phpunit/phpunit": "~4.2" + "phpunit/phpunit": "^6.2.4" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -1426,20 +1556,20 @@ "keywords": [ "tokenizer" ], - "time": "2017-02-27T10:12:30+00:00" + "time": "2017-11-27T05:48:46+00:00" }, { "name": "phpunit/phpunit", - "version": "6.1.4", + "version": "6.4.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "42b7f394a8e009516582331b1e03a1aba40175d1" + "reference": "562f7dc75d46510a4ed5d16189ae57fbe45a9932" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/42b7f394a8e009516582331b1e03a1aba40175d1", - "reference": "42b7f394a8e009516582331b1e03a1aba40175d1", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/562f7dc75d46510a4ed5d16189ae57fbe45a9932", + "reference": "562f7dc75d46510a4ed5d16189ae57fbe45a9932", "shasum": "" }, "require": { @@ -1448,24 +1578,24 @@ "ext-libxml": "*", "ext-mbstring": "*", "ext-xml": "*", - "myclabs/deep-copy": "^1.3", + "myclabs/deep-copy": "^1.6.1", "phar-io/manifest": "^1.0.1", "phar-io/version": "^1.0", "php": "^7.0", "phpspec/prophecy": "^1.7", - "phpunit/php-code-coverage": "^5.2", - "phpunit/php-file-iterator": "^1.4", - "phpunit/php-text-template": "^1.2", - "phpunit/php-timer": "^1.0.6", - "phpunit/phpunit-mock-objects": "^4.0", - "sebastian/comparator": "^2.0", - "sebastian/diff": "^1.4.3 || ^2.0", - "sebastian/environment": "^3.0.2", + "phpunit/php-code-coverage": "^5.2.2", + "phpunit/php-file-iterator": "^1.4.2", + "phpunit/php-text-template": "^1.2.1", + "phpunit/php-timer": "^1.0.9", + "phpunit/phpunit-mock-objects": "^4.0.3", + "sebastian/comparator": "^2.0.2", + "sebastian/diff": "^2.0", + "sebastian/environment": "^3.1", "sebastian/exporter": "^3.1", - "sebastian/global-state": "^1.1 || ^2.0", - "sebastian/object-enumerator": "^3.0.2", + "sebastian/global-state": "^2.0", + "sebastian/object-enumerator": "^3.0.3", "sebastian/resource-operations": "^1.0", - "sebastian/version": "^2.0" + "sebastian/version": "^2.0.1" }, "conflict": { "phpdocumentor/reflection-docblock": "3.0.2", @@ -1484,7 +1614,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "6.1.x-dev" + "dev-master": "6.4.x-dev" } }, "autoload": { @@ -1510,26 +1640,26 @@ "testing", "xunit" ], - "time": "2017-05-22T07:45:30+00:00" + "time": "2017-11-08T11:26:09+00:00" }, { "name": "phpunit/phpunit-mock-objects", - "version": "4.0.1", + "version": "4.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", - "reference": "eabce450df194817a7d7e27e19013569a903a2bf" + "reference": "2f789b59ab89669015ad984afa350c4ec577ade0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/eabce450df194817a7d7e27e19013569a903a2bf", - "reference": "eabce450df194817a7d7e27e19013569a903a2bf", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/2f789b59ab89669015ad984afa350c4ec577ade0", + "reference": "2f789b59ab89669015ad984afa350c4ec577ade0", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.0.2", + "doctrine/instantiator": "^1.0.5", "php": "^7.0", - "phpunit/php-text-template": "^1.2", + "phpunit/php-text-template": "^1.2.1", "sebastian/exporter": "^3.0" }, "conflict": { @@ -1569,29 +1699,33 @@ "mock", "xunit" ], - "time": "2017-03-03T06:30:20+00:00" + "time": "2017-08-03T14:08:16+00:00" }, { "name": "pimple/pimple", - "version": "v3.0.2", + "version": "v3.2.2", "source": { "type": "git", "url": "https://github.com/silexphp/Pimple.git", - "reference": "a30f7d6e57565a2e1a316e1baf2a483f788b258a" + "reference": "4d45fb62d96418396ec58ba76e6f065bca16e10a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/silexphp/Pimple/zipball/a30f7d6e57565a2e1a316e1baf2a483f788b258a", - "reference": "a30f7d6e57565a2e1a316e1baf2a483f788b258a", + "url": "https://api.github.com/repos/silexphp/Pimple/zipball/4d45fb62d96418396ec58ba76e6f065bca16e10a", + "reference": "4d45fb62d96418396ec58ba76e6f065bca16e10a", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": ">=5.3.0", + "psr/container": "^1.0" + }, + "require-dev": { + "symfony/phpunit-bridge": "^3.2" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "3.2.x-dev" } }, "autoload": { @@ -1615,7 +1749,7 @@ "container", "dependency injection" ], - "time": "2015-09-11T15:10:35+00:00" + "time": "2017-07-23T07:32:15+00:00" }, { "name": "psr/container", @@ -1760,7 +1894,7 @@ "AGPL-3.0" ], "description": "Helper for code reviews", - "time": "2017-05-22 09:46:29" + "time": "2017-05-22T09:46:29+00:00" }, { "name": "roave/security-advisories", @@ -1768,26 +1902,28 @@ "source": { "type": "git", "url": "https://github.com/Roave/SecurityAdvisories.git", - "reference": "ccffea64be8575eaa7ad09cd16dfeedfa4711607" + "reference": "f793fe6ff54acabd9bc9f76f4a9ad3c89a68c789" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/ccffea64be8575eaa7ad09cd16dfeedfa4711607", - "reference": "ccffea64be8575eaa7ad09cd16dfeedfa4711607", + "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/f793fe6ff54acabd9bc9f76f4a9ad3c89a68c789", + "reference": "f793fe6ff54acabd9bc9f76f4a9ad3c89a68c789", "shasum": "" }, "conflict": { "adodb/adodb-php": "<5.20.6", - "amphp/artax": ">=2,<2.0.6|<1.0.6", + "amphp/artax": "<1.0.6|>=2,<2.0.6", "aws/aws-sdk-php": ">=3,<3.2.1", "bugsnag/bugsnag-laravel": ">=2,<2.0.2", - "cakephp/cakephp": ">=3,<3.0.15|>=2,<2.4.99|>=2.5,<2.5.99|>=2.6,<2.6.12|>=1.3,<1.3.18|>=2.7,<2.7.6|>=3.1,<3.1.4", + "cakephp/cakephp": ">=1.3,<1.3.18|>=2,<2.4.99|>=2.5,<2.5.99|>=2.6,<2.6.12|>=2.7,<2.7.6|>=3,<3.0.15|>=3.1,<3.1.4", "cart2quote/module-quotation": ">=4.1.6,<=4.4.5|>=5,<5.4.4", - "cartalyst/sentry": "<2.1", + "cartalyst/sentry": "<=2.1.6", "codeigniter/framework": "<=3.0.6", "composer/composer": "<=1.0.0-alpha11", "contao-components/mediaelement": ">=2.14.2,<2.21.1", - "contao/core": ">=2.11,<3.5.15", + "contao/core": ">=2,<3.5.31", + "contao/core-bundle": ">=4,<4.4.8", + "contao/listing-bundle": ">=4,<4.4.8", "doctrine/annotations": ">=1,<1.2.7", "doctrine/cache": ">=1,<1.3.2|>=1.4,<1.4.2", "doctrine/common": ">=2,<2.4.3|>=2.5,<2.5.1", @@ -1798,8 +1934,9 @@ "doctrine/mongodb-odm-bundle": ">=2,<3.0.1", "doctrine/orm": ">=2,<2.4.8|>=2.5,<2.5.1", "dompdf/dompdf": ">=0.6,<0.6.2", - "drupal/core": ">=8,<8.2.8|>=8.3,<8.3.1", - "drupal/drupal": ">=8,<8.2.8|>=8.3,<8.3.1", + "drupal/core": ">=8,<8.3.7", + "drupal/drupal": ">=8,<8.3.7", + "ezsystems/ezpublish-legacy": ">=5.3,<5.3.12.2|>=5.4,<5.4.10.1|>=2017.8,<2017.8.1.1", "firebase/php-jwt": "<2", "friendsofsymfony/rest-bundle": ">=1.2,<1.2.2", "friendsofsymfony/user-bundle": ">=1.2,<1.3.5", @@ -1815,33 +1952,38 @@ "magento/magento2ce": ">=2,<2.2", "monolog/monolog": ">=1.8,<1.12", "namshi/jose": "<2.2", + "onelogin/php-saml": "<2.10.4", "oro/crm": ">=1.7,<1.7.4", "oro/platform": ">=1.7,<1.7.4", - "phpmailer/phpmailer": ">=5,<5.2.22", + "phpmailer/phpmailer": ">=5,<5.2.24", + "phpunit/phpunit": ">=4.8.19,<4.8.28|>=5.0.10,<5.6.3", + "phpxmlrpc/extras": "<6.0.1", "pusher/pusher-php-server": "<2.2.1", "sabre/dav": ">=1.6,<1.6.99|>=1.7,<1.7.11|>=1.8,<1.8.9", - "shopware/shopware": "<4.4|>=5,<5.2.16", - "silverstripe/cms": ">=3.1,<3.1.11|>=3,<=3.0.11", + "shopware/shopware": "<5.2.25", + "silverstripe/cms": ">=3,<=3.0.11|>=3.1,<3.1.11", "silverstripe/forum": "<=0.6.1|>=0.7,<=0.7.3", "silverstripe/framework": ">=3,<3.3", "silverstripe/userforms": "<3", "simplesamlphp/saml2": "<1.8.1|>=1.9,<1.9.1|>=1.10,<1.10.3|>=2,<2.3.3", - "simplesamlphp/simplesamlphp": "<1.14.12", + "simplesamlphp/simplesamlphp": "<1.14.16", "simplesamlphp/simplesamlphp-module-infocard": "<1.0.1", "socalnick/scn-social-auth": "<1.15.2", "squizlabs/php_codesniffer": ">=1,<2.8.1", "swiftmailer/swiftmailer": ">=4,<5.4.5", "symfony/dependency-injection": ">=2,<2.0.17", - "symfony/form": ">=2.3,<2.3.35|>=2.4,<2.6.12|>=2.7,<2.7.7", + "symfony/form": ">=2.3,<2.3.35|>=2.4,<2.6.12|>=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", "symfony/framework-bundle": ">=2,<2.3.18|>=2.4,<2.4.8|>=2.5,<2.5.2", "symfony/http-foundation": ">=2,<2.3.27|>=2.4,<2.5.11|>=2.6,<2.6.6", "symfony/http-kernel": ">=2,<2.3.29|>=2.4,<2.5.12|>=2.6,<2.6.8", + "symfony/intl": ">=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", "symfony/routing": ">=2,<2.0.19", - "symfony/security": ">=2.3,<2.3.37|>=2.4,<2.6.13|>=2.7,<2.7.9|>=2,<2.0.25|>=2.1,<2.1.13|>=2.2,<2.2.9", - "symfony/security-core": ">=2.8,<2.8.6|>=3,<3.0.6|>=2.4,<2.6.13|>=2.7,<2.7.9", - "symfony/security-http": ">=2.4,<2.7.13|>=2.3,<2.3.41|>=2.8,<2.8.6|>=3,<3.0.6", + "symfony/security": ">=2,<2.0.25|>=2.1,<2.1.13|>=2.2,<2.2.9|>=2.3,<2.3.37|>=2.4,<2.6.13|>=2.7,<2.7.9|>=2.7.30,<2.7.32|>=2.8.23,<2.8.25|>=3.2.10,<3.2.12|>=3.3.3,<3.3.5", + "symfony/security-core": ">=2.4,<2.6.13|>=2.7,<2.7.9|>=2.7.30,<2.7.32|>=2.8,<2.8.6|>=2.8.23,<2.8.25|>=3,<3.0.6|>=3.2.10,<3.2.12|>=3.3.3,<3.3.5", + "symfony/security-csrf": ">=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", + "symfony/security-http": ">=2.3,<2.3.41|>=2.4,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", "symfony/serializer": ">=2,<2.0.11", - "symfony/symfony": ">=2,<2.3.41|>=2.4,<2.7.13|>=2.8,<2.8.6|>=3,<3.0.6", + "symfony/symfony": ">=2,<2.3.41|>=2.4,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", "symfony/translation": ">=2,<2.0.17", "symfony/validator": ">=2,<2.0.24|>=2.1,<2.1.12|>=2.2,<2.2.5|>=2.3,<2.3.3", "symfony/web-profiler-bundle": ">=2,<2.3.19|>=2.4,<2.4.9|>=2.5,<2.5.4", @@ -1849,8 +1991,8 @@ "thelia/backoffice-default-template": ">=2.1,<2.1.2", "thelia/thelia": ">=2.1.0-beta1,<2.1.3|>=2.1,<2.1.2", "twig/twig": "<1.20", - "typo3/cms": ">=6.2,<6.2.30|>=8,<8.6.1|>=7,<7.6.16", - "typo3/flow": ">=2.3,<2.3.16|>=3,<3.0.10|>=3.1,<3.1.7|>=3.2,<3.2.7|>=3.3,<3.3.5|>=1,<1.0.4|>=1.1,<1.1.1|>=2,<2.0.1", + "typo3/cms": ">=6.2,<6.2.30|>=7,<7.6.22|>=8,<8.7.5", + "typo3/flow": ">=1,<1.0.4|>=1.1,<1.1.1|>=2,<2.0.1|>=2.3,<2.3.16|>=3,<3.0.10|>=3.1,<3.1.7|>=3.2,<3.2.7|>=3.3,<3.3.5", "typo3/neos": ">=1.1,<1.1.3|>=1.2,<1.2.13|>=2,<2.0.4", "willdurand/js-translation-bundle": "<2.1.1", "yiisoft/yii": ">=1.1.14,<1.1.15", @@ -1878,6 +2020,7 @@ "zendframework/zendframework1": "<1.12.20", "zendframework/zendopenid": ">=2,<2.0.2", "zendframework/zendxml": ">=1,<1.0.1", + "zetacomponents/mail": "<1.8.2", "zf-commons/zfc-user": "<1.2.2", "zfcampus/zf-apigility-doctrine": ">=1,<1.0.3", "zfr/zfr-oauth2-server-module": "<0.1.2" @@ -1895,7 +2038,7 @@ } ], "description": "Prevents installation of composer packages with known security vulnerabilities: no API, simply require it", - "time": "2017-05-13T14:02:28+00:00" + "time": "2017-11-24T16:44:41+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", @@ -1944,30 +2087,30 @@ }, { "name": "sebastian/comparator", - "version": "2.0.0", + "version": "2.1.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "20f84f468cb67efee293246e6a09619b891f55f0" + "reference": "1174d9018191e93cb9d719edec01257fc05f8158" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/20f84f468cb67efee293246e6a09619b891f55f0", - "reference": "20f84f468cb67efee293246e6a09619b891f55f0", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/1174d9018191e93cb9d719edec01257fc05f8158", + "reference": "1174d9018191e93cb9d719edec01257fc05f8158", "shasum": "" }, "require": { "php": "^7.0", - "sebastian/diff": "^1.2", - "sebastian/exporter": "^3.0" + "sebastian/diff": "^2.0", + "sebastian/exporter": "^3.1" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "phpunit/phpunit": "^6.4" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "2.1.x-dev" } }, "autoload": { @@ -1998,38 +2141,38 @@ } ], "description": "Provides the functionality to compare PHP values for equality", - "homepage": "http://www.github.com/sebastianbergmann/comparator", + "homepage": "https://github.com/sebastianbergmann/comparator", "keywords": [ "comparator", "compare", "equality" ], - "time": "2017-03-03T06:26:08+00:00" + "time": "2017-11-03T07:16:52+00:00" }, { "name": "sebastian/diff", - "version": "1.4.3", + "version": "2.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "7f066a26a962dbe58ddea9f72a4e82874a3975a4" + "reference": "347c1d8b49c5c3ee30c7040ea6fc446790e6bddd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/7f066a26a962dbe58ddea9f72a4e82874a3975a4", - "reference": "7f066a26a962dbe58ddea9f72a4e82874a3975a4", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/347c1d8b49c5c3ee30c7040ea6fc446790e6bddd", + "reference": "347c1d8b49c5c3ee30c7040ea6fc446790e6bddd", "shasum": "" }, "require": { - "php": "^5.3.3 || ^7.0" + "php": "^7.0" }, "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0" + "phpunit/phpunit": "^6.2" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -2056,20 +2199,20 @@ "keywords": [ "diff" ], - "time": "2017-05-22T07:24:03+00:00" + "time": "2017-08-03T08:09:46+00:00" }, { "name": "sebastian/environment", - "version": "3.0.3", + "version": "3.1.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "02b6b2c7aefe2cdb1185b8dbf8718b0bcedf3ab3" + "reference": "cd0871b3975fb7fc44d11314fd1ee20925fce4f5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/02b6b2c7aefe2cdb1185b8dbf8718b0bcedf3ab3", - "reference": "02b6b2c7aefe2cdb1185b8dbf8718b0bcedf3ab3", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/cd0871b3975fb7fc44d11314fd1ee20925fce4f5", + "reference": "cd0871b3975fb7fc44d11314fd1ee20925fce4f5", "shasum": "" }, "require": { @@ -2081,7 +2224,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0.x-dev" + "dev-master": "3.1.x-dev" } }, "autoload": { @@ -2106,7 +2249,7 @@ "environment", "hhvm" ], - "time": "2017-05-18T10:10:00+00:00" + "time": "2017-07-01T08:51:00+00:00" }, { "name": "sebastian/exporter", @@ -2177,20 +2320,20 @@ }, { "name": "sebastian/finder-facade", - "version": "1.2.1", + "version": "1.2.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/finder-facade.git", - "reference": "2a6f7f57efc0aa2d23297d9fd9e2a03111a8c0b9" + "reference": "4a3174709c2dc565fe5fb26fcf827f6a1fc7b09f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/finder-facade/zipball/2a6f7f57efc0aa2d23297d9fd9e2a03111a8c0b9", - "reference": "2a6f7f57efc0aa2d23297d9fd9e2a03111a8c0b9", + "url": "https://api.github.com/repos/sebastianbergmann/finder-facade/zipball/4a3174709c2dc565fe5fb26fcf827f6a1fc7b09f", + "reference": "4a3174709c2dc565fe5fb26fcf827f6a1fc7b09f", "shasum": "" }, "require": { - "symfony/finder": "~2.3|~3.0", + "symfony/finder": "~2.3|~3.0|~4.0", "theseer/fdomdocument": "~1.3" }, "type": "library", @@ -2212,7 +2355,7 @@ ], "description": "FinderFacade is a convenience wrapper for Symfony's Finder component.", "homepage": "https://github.com/sebastianbergmann/finder-facade", - "time": "2016-02-17T07:02:23+00:00" + "time": "2017-11-18T17:31:49+00:00" }, { "name": "sebastian/git", @@ -2313,21 +2456,21 @@ }, { "name": "sebastian/object-enumerator", - "version": "3.0.2", + "version": "3.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "31dd3379d16446c5d86dec32ab1ad1f378581ad8" + "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/31dd3379d16446c5d86dec32ab1ad1f378581ad8", - "reference": "31dd3379d16446c5d86dec32ab1ad1f378581ad8", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/7cfd9e65d11ffb5af41198476395774d4c8a84c5", + "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5", "shasum": "" }, "require": { "php": "^7.0", - "sebastian/object-reflector": "^1.0", + "sebastian/object-reflector": "^1.1.1", "sebastian/recursion-context": "^3.0" }, "require-dev": { @@ -2356,7 +2499,7 @@ ], "description": "Traverses array structures and object graphs to enumerate all referenced objects", "homepage": "https://github.com/sebastianbergmann/object-enumerator/", - "time": "2017-03-12T15:17:29+00:00" + "time": "2017-08-03T12:35:26+00:00" }, { "name": "sebastian/object-reflector", @@ -2405,24 +2548,24 @@ }, { "name": "sebastian/phpcpd", - "version": "3.0.0", + "version": "3.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpcpd.git", - "reference": "d7006078b75a34c9250831c3453a2e256a687615" + "reference": "dfed51c1288790fc957c9433e2f49ab152e8a564" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpcpd/zipball/d7006078b75a34c9250831c3453a2e256a687615", - "reference": "d7006078b75a34c9250831c3453a2e256a687615", + "url": "https://api.github.com/repos/sebastianbergmann/phpcpd/zipball/dfed51c1288790fc957c9433e2f49ab152e8a564", + "reference": "dfed51c1288790fc957c9433e2f49ab152e8a564", "shasum": "" }, "require": { "php": "^5.6|^7.0", "phpunit/php-timer": "^1.0.6", "sebastian/finder-facade": "^1.1", - "sebastian/version": "^2.0", - "symfony/console": "^3.0" + "sebastian/version": "^1.0|^2.0", + "symfony/console": "^2.7|^3.0|^4.0" }, "bin": [ "phpcpd" @@ -2451,7 +2594,7 @@ ], "description": "Copy/Paste Detector (CPD) for PHP code.", "homepage": "https://github.com/sebastianbergmann/phpcpd", - "time": "2017-02-05T07:48:01+00:00" + "time": "2017-11-16T08:49:28+00:00" }, { "name": "sebastian/recursion-context", @@ -2625,16 +2768,16 @@ }, { "name": "slim/slim", - "version": "3.8.1", + "version": "3.9.2", "source": { "type": "git", "url": "https://github.com/slimphp/Slim.git", - "reference": "5385302707530b2bccee1769613ad769859b826d" + "reference": "4086d0106cf5a7135c69fce4161fe355a8feb118" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/slimphp/Slim/zipball/5385302707530b2bccee1769613ad769859b826d", - "reference": "5385302707530b2bccee1769613ad769859b826d", + "url": "https://api.github.com/repos/slimphp/Slim/zipball/4086d0106cf5a7135c69fce4161fe355a8feb118", + "reference": "4086d0106cf5a7135c69fce4161fe355a8feb118", "shasum": "" }, "require": { @@ -2692,20 +2835,20 @@ "micro", "router" ], - "time": "2017-03-19T17:55:20+00:00" + "time": "2017-11-26T19:13:09+00:00" }, { "name": "squizlabs/php_codesniffer", - "version": "3.0.0", + "version": "3.1.1", "source": { "type": "git", "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", - "reference": "b95ff2c3b122a3ee4b57d149a57d2afce65522c3" + "reference": "d667e245d5dcd4d7bf80f26f2c947d476b66213e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/b95ff2c3b122a3ee4b57d149a57d2afce65522c3", - "reference": "b95ff2c3b122a3ee4b57d149a57d2afce65522c3", + "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/d667e245d5dcd4d7bf80f26f2c947d476b66213e", + "reference": "d667e245d5dcd4d7bf80f26f2c947d476b66213e", "shasum": "" }, "require": { @@ -2715,7 +2858,7 @@ "php": ">=5.4.0" }, "require-dev": { - "phpunit/phpunit": "~4.0" + "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0" }, "bin": [ "bin/phpcs", @@ -2743,27 +2886,33 @@ "phpcs", "standards" ], - "time": "2017-05-04T00:33:04+00:00" + "time": "2017-10-16T22:40:25+00:00" }, { "name": "symfony/config", - "version": "v3.2.8", + "version": "v3.3.13", "source": { "type": "git", "url": "https://github.com/symfony/config.git", - "reference": "e5533fcc0b3dd377626153b2852707878f363728" + "reference": "8d2649077dc54dfbaf521d31f217383d82303c5f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/config/zipball/e5533fcc0b3dd377626153b2852707878f363728", - "reference": "e5533fcc0b3dd377626153b2852707878f363728", + "url": "https://api.github.com/repos/symfony/config/zipball/8d2649077dc54dfbaf521d31f217383d82303c5f", + "reference": "8d2649077dc54dfbaf521d31f217383d82303c5f", "shasum": "" }, "require": { - "php": ">=5.5.9", + "php": "^5.5.9|>=7.0.8", "symfony/filesystem": "~2.8|~3.0" }, + "conflict": { + "symfony/dependency-injection": "<3.3", + "symfony/finder": "<3.3" + }, "require-dev": { + "symfony/dependency-injection": "~3.3", + "symfony/finder": "~3.3", "symfony/yaml": "~3.0" }, "suggest": { @@ -2772,7 +2921,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-master": "3.3-dev" } }, "autoload": { @@ -2799,29 +2948,34 @@ ], "description": "Symfony Config Component", "homepage": "https://symfony.com", - "time": "2017-04-12T14:13:17+00:00" + "time": "2017-11-07T14:16:22+00:00" }, { "name": "symfony/console", - "version": "v3.2.8", + "version": "v3.3.13", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "a7a17e0c6c3c4d70a211f80782e4b90ddadeaa38" + "reference": "63cd7960a0a522c3537f6326706d7f3b8de65805" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/a7a17e0c6c3c4d70a211f80782e4b90ddadeaa38", - "reference": "a7a17e0c6c3c4d70a211f80782e4b90ddadeaa38", + "url": "https://api.github.com/repos/symfony/console/zipball/63cd7960a0a522c3537f6326706d7f3b8de65805", + "reference": "63cd7960a0a522c3537f6326706d7f3b8de65805", "shasum": "" }, "require": { - "php": ">=5.5.9", + "php": "^5.5.9|>=7.0.8", "symfony/debug": "~2.8|~3.0", "symfony/polyfill-mbstring": "~1.0" }, + "conflict": { + "symfony/dependency-injection": "<3.3" + }, "require-dev": { "psr/log": "~1.0", + "symfony/config": "~3.3", + "symfony/dependency-injection": "~3.3", "symfony/event-dispatcher": "~2.8|~3.0", "symfony/filesystem": "~2.8|~3.0", "symfony/process": "~2.8|~3.0" @@ -2835,7 +2989,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-master": "3.3-dev" } }, "autoload": { @@ -2862,37 +3016,36 @@ ], "description": "Symfony Console Component", "homepage": "https://symfony.com", - "time": "2017-04-26T01:39:17+00:00" + "time": "2017-11-16T15:24:32+00:00" }, { "name": "symfony/debug", - "version": "v3.2.8", + "version": "v3.3.13", "source": { "type": "git", "url": "https://github.com/symfony/debug.git", - "reference": "fd6eeee656a5a7b384d56f1072243fe1c0e81686" + "reference": "74557880e2846b5c84029faa96b834da37e29810" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/fd6eeee656a5a7b384d56f1072243fe1c0e81686", - "reference": "fd6eeee656a5a7b384d56f1072243fe1c0e81686", + "url": "https://api.github.com/repos/symfony/debug/zipball/74557880e2846b5c84029faa96b834da37e29810", + "reference": "74557880e2846b5c84029faa96b834da37e29810", "shasum": "" }, "require": { - "php": ">=5.5.9", + "php": "^5.5.9|>=7.0.8", "psr/log": "~1.0" }, "conflict": { "symfony/http-kernel": ">=2.3,<2.3.24|~2.4.0|>=2.5,<2.5.9|>=2.6,<2.6.2" }, "require-dev": { - "symfony/class-loader": "~2.8|~3.0", "symfony/http-kernel": "~2.8|~3.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-master": "3.3-dev" } }, "autoload": { @@ -2919,43 +3072,50 @@ ], "description": "Symfony Debug Component", "homepage": "https://symfony.com", - "time": "2017-04-19T20:17:50+00:00" + "time": "2017-11-10T16:38:39+00:00" }, { "name": "symfony/dependency-injection", - "version": "v3.2.8", + "version": "v3.3.13", "source": { "type": "git", "url": "https://github.com/symfony/dependency-injection.git", - "reference": "5e00857475b6d1fa31ff4c76f1fddf1cfa9e8d59" + "reference": "4e84f5af2c2d51ee3dee72df40b7fc08f49b4ab8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/5e00857475b6d1fa31ff4c76f1fddf1cfa9e8d59", - "reference": "5e00857475b6d1fa31ff4c76f1fddf1cfa9e8d59", + "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/4e84f5af2c2d51ee3dee72df40b7fc08f49b4ab8", + "reference": "4e84f5af2c2d51ee3dee72df40b7fc08f49b4ab8", "shasum": "" }, "require": { - "php": ">=5.5.9" + "php": "^5.5.9|>=7.0.8", + "psr/container": "^1.0" }, "conflict": { - "symfony/yaml": "<3.2" + "symfony/config": "<3.3.1", + "symfony/finder": "<3.3", + "symfony/yaml": "<3.3" + }, + "provide": { + "psr/container-implementation": "1.0" }, "require-dev": { - "symfony/config": "~2.8|~3.0", + "symfony/config": "~3.3", "symfony/expression-language": "~2.8|~3.0", - "symfony/yaml": "~3.2" + "symfony/yaml": "~3.3" }, "suggest": { "symfony/config": "", "symfony/expression-language": "For using expressions in service container configuration", + "symfony/finder": "For using double-star glob patterns or when GLOB_BRACE portability is required", "symfony/proxy-manager-bridge": "Generate service proxies to lazy load them", "symfony/yaml": "" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-master": "3.3-dev" } }, "autoload": { @@ -2982,29 +3142,32 @@ ], "description": "Symfony DependencyInjection Component", "homepage": "https://symfony.com", - "time": "2017-04-26T01:39:17+00:00" + "time": "2017-11-13T18:10:32+00:00" }, { "name": "symfony/event-dispatcher", - "version": "v3.2.8", + "version": "v3.3.13", "source": { "type": "git", "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "b8a401f733b43251e1d088c589368b2a94155e40" + "reference": "271d8c27c3ec5ecee6e2ac06016232e249d638d9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/b8a401f733b43251e1d088c589368b2a94155e40", - "reference": "b8a401f733b43251e1d088c589368b2a94155e40", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/271d8c27c3ec5ecee6e2ac06016232e249d638d9", + "reference": "271d8c27c3ec5ecee6e2ac06016232e249d638d9", "shasum": "" }, "require": { - "php": ">=5.5.9" + "php": "^5.5.9|>=7.0.8" + }, + "conflict": { + "symfony/dependency-injection": "<3.3" }, "require-dev": { "psr/log": "~1.0", "symfony/config": "~2.8|~3.0", - "symfony/dependency-injection": "~2.8|~3.0", + "symfony/dependency-injection": "~3.3", "symfony/expression-language": "~2.8|~3.0", "symfony/stopwatch": "~2.8|~3.0" }, @@ -3015,7 +3178,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-master": "3.3-dev" } }, "autoload": { @@ -3042,29 +3205,29 @@ ], "description": "Symfony EventDispatcher Component", "homepage": "https://symfony.com", - "time": "2017-05-01T14:58:48+00:00" + "time": "2017-11-05T15:47:03+00:00" }, { "name": "symfony/filesystem", - "version": "v3.2.8", + "version": "v3.3.13", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "040651db13cf061827a460cc10f6e36a445c45b4" + "reference": "77db266766b54db3ee982fe51868328b887ce15c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/040651db13cf061827a460cc10f6e36a445c45b4", - "reference": "040651db13cf061827a460cc10f6e36a445c45b4", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/77db266766b54db3ee982fe51868328b887ce15c", + "reference": "77db266766b54db3ee982fe51868328b887ce15c", "shasum": "" }, "require": { - "php": ">=5.5.9" + "php": "^5.5.9|>=7.0.8" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-master": "3.3-dev" } }, "autoload": { @@ -3091,29 +3254,29 @@ ], "description": "Symfony Filesystem Component", "homepage": "https://symfony.com", - "time": "2017-04-12T14:13:17+00:00" + "time": "2017-11-07T14:12:55+00:00" }, { "name": "symfony/finder", - "version": "v3.2.8", + "version": "v3.3.13", "source": { "type": "git", "url": "https://github.com/symfony/finder.git", - "reference": "9cf076f8f492f4b1ffac40aae9c2d287b4ca6930" + "reference": "138af5ec075d4b1d1bd19de08c38a34bb2d7d880" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/9cf076f8f492f4b1ffac40aae9c2d287b4ca6930", - "reference": "9cf076f8f492f4b1ffac40aae9c2d287b4ca6930", + "url": "https://api.github.com/repos/symfony/finder/zipball/138af5ec075d4b1d1bd19de08c38a34bb2d7d880", + "reference": "138af5ec075d4b1d1bd19de08c38a34bb2d7d880", "shasum": "" }, "require": { - "php": ">=5.5.9" + "php": "^5.5.9|>=7.0.8" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-master": "3.3-dev" } }, "autoload": { @@ -3140,29 +3303,29 @@ ], "description": "Symfony Finder Component", "homepage": "https://symfony.com", - "time": "2017-04-12T14:13:17+00:00" + "time": "2017-11-05T15:47:03+00:00" }, { "name": "symfony/options-resolver", - "version": "v3.2.8", + "version": "v3.3.13", "source": { "type": "git", "url": "https://github.com/symfony/options-resolver.git", - "reference": "8cbb4f23414e2a5e92690cf67680a979a461113c" + "reference": "623d9c210a137205f7e6e98166105625402cbb2f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/options-resolver/zipball/8cbb4f23414e2a5e92690cf67680a979a461113c", - "reference": "8cbb4f23414e2a5e92690cf67680a979a461113c", + "url": "https://api.github.com/repos/symfony/options-resolver/zipball/623d9c210a137205f7e6e98166105625402cbb2f", + "reference": "623d9c210a137205f7e6e98166105625402cbb2f", "shasum": "" }, "require": { - "php": ">=5.5.9" + "php": "^5.5.9|>=7.0.8" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-master": "3.3-dev" } }, "autoload": { @@ -3194,20 +3357,20 @@ "configuration", "options" ], - "time": "2017-04-12T14:13:17+00:00" + "time": "2017-11-05T15:47:03+00:00" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.3.0", + "version": "v1.6.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "e79d363049d1c2128f133a2667e4f4190904f7f4" + "reference": "2ec8b39c38cb16674bbf3fea2b6ce5bf117e1296" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/e79d363049d1c2128f133a2667e4f4190904f7f4", - "reference": "e79d363049d1c2128f133a2667e4f4190904f7f4", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/2ec8b39c38cb16674bbf3fea2b6ce5bf117e1296", + "reference": "2ec8b39c38cb16674bbf3fea2b6ce5bf117e1296", "shasum": "" }, "require": { @@ -3219,7 +3382,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3-dev" + "dev-master": "1.6-dev" } }, "autoload": { @@ -3253,20 +3416,20 @@ "portable", "shim" ], - "time": "2016-11-14T01:06:16+00:00" + "time": "2017-10-11T12:05:26+00:00" }, { "name": "symfony/polyfill-php70", - "version": "v1.3.0", + "version": "v1.6.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php70.git", - "reference": "13ce343935f0f91ca89605a2f6ca6f5c2f3faac2" + "reference": "0442b9c0596610bd24ae7b5f0a6cdbbc16d9fcff" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php70/zipball/13ce343935f0f91ca89605a2f6ca6f5c2f3faac2", - "reference": "13ce343935f0f91ca89605a2f6ca6f5c2f3faac2", + "url": "https://api.github.com/repos/symfony/polyfill-php70/zipball/0442b9c0596610bd24ae7b5f0a6cdbbc16d9fcff", + "reference": "0442b9c0596610bd24ae7b5f0a6cdbbc16d9fcff", "shasum": "" }, "require": { @@ -3276,7 +3439,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3-dev" + "dev-master": "1.6-dev" } }, "autoload": { @@ -3312,37 +3475,34 @@ "portable", "shim" ], - "time": "2016-11-14T01:06:16+00:00" + "time": "2017-10-11T12:05:26+00:00" }, { - "name": "symfony/polyfill-xml", - "version": "v1.3.0", + "name": "symfony/polyfill-php72", + "version": "v1.6.0", "source": { "type": "git", - "url": "https://github.com/symfony/polyfill-xml.git", - "reference": "64b6a864f18ab4fddad49f5025f805f6781dfabd" + "url": "https://github.com/symfony/polyfill-php72.git", + "reference": "6de4f4884b97abbbed9f0a84a95ff2ff77254254" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-xml/zipball/64b6a864f18ab4fddad49f5025f805f6781dfabd", - "reference": "64b6a864f18ab4fddad49f5025f805f6781dfabd", + "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/6de4f4884b97abbbed9f0a84a95ff2ff77254254", + "reference": "6de4f4884b97abbbed9f0a84a95ff2ff77254254", "shasum": "" }, "require": { "php": ">=5.3.3" }, - "suggest": { - "ext-xml": "For best performance" - }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3-dev" + "dev-master": "1.6-dev" } }, "autoload": { "psr-4": { - "Symfony\\Polyfill\\Xml\\": "" + "Symfony\\Polyfill\\Php72\\": "" }, "files": [ "bootstrap.php" @@ -3362,7 +3522,7 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony polyfill for xml's utf8_encode and utf8_decode functions", + "description": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", "homepage": "https://symfony.com", "keywords": [ "compatibility", @@ -3370,29 +3530,29 @@ "portable", "shim" ], - "time": "2016-11-14T01:06:16+00:00" + "time": "2017-10-11T12:05:26+00:00" }, { "name": "symfony/process", - "version": "v3.2.8", + "version": "v3.3.13", "source": { "type": "git", "url": "https://github.com/symfony/process.git", - "reference": "999c2cf5061e627e6cd551dc9ebf90dd1d11d9f0" + "reference": "a56a3989fb762d7b19a0cf8e7693ee99a6ffb78d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/999c2cf5061e627e6cd551dc9ebf90dd1d11d9f0", - "reference": "999c2cf5061e627e6cd551dc9ebf90dd1d11d9f0", + "url": "https://api.github.com/repos/symfony/process/zipball/a56a3989fb762d7b19a0cf8e7693ee99a6ffb78d", + "reference": "a56a3989fb762d7b19a0cf8e7693ee99a6ffb78d", "shasum": "" }, "require": { - "php": ">=5.5.9" + "php": "^5.5.9|>=7.0.8" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-master": "3.3-dev" } }, "autoload": { @@ -3419,29 +3579,29 @@ ], "description": "Symfony Process Component", "homepage": "https://symfony.com", - "time": "2017-04-12T14:13:17+00:00" + "time": "2017-11-13T15:31:11+00:00" }, { "name": "symfony/stopwatch", - "version": "v3.2.8", + "version": "v3.3.13", "source": { "type": "git", "url": "https://github.com/symfony/stopwatch.git", - "reference": "5a0105afb670dbd38f521105c444de1b8e10cfe3" + "reference": "1e93c3139ef6c799831fe03efd0fb1c7aecb3365" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/stopwatch/zipball/5a0105afb670dbd38f521105c444de1b8e10cfe3", - "reference": "5a0105afb670dbd38f521105c444de1b8e10cfe3", + "url": "https://api.github.com/repos/symfony/stopwatch/zipball/1e93c3139ef6c799831fe03efd0fb1c7aecb3365", + "reference": "1e93c3139ef6c799831fe03efd0fb1c7aecb3365", "shasum": "" }, "require": { - "php": ">=5.5.9" + "php": "^5.5.9|>=7.0.8" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2-dev" + "dev-master": "3.3-dev" } }, "autoload": { @@ -3468,20 +3628,20 @@ ], "description": "Symfony Stopwatch Component", "homepage": "https://symfony.com", - "time": "2017-04-12T14:13:17+00:00" + "time": "2017-11-10T19:02:53+00:00" }, { "name": "theseer/fdomdocument", - "version": "1.6.5", + "version": "1.6.6", "source": { "type": "git", "url": "https://github.com/theseer/fDOMDocument.git", - "reference": "8dcfd392135a5bd938c3c83ea71419501ad9855d" + "reference": "6e8203e40a32a9c770bcb62fe37e68b948da6dca" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theseer/fDOMDocument/zipball/8dcfd392135a5bd938c3c83ea71419501ad9855d", - "reference": "8dcfd392135a5bd938c3c83ea71419501ad9855d", + "url": "https://api.github.com/repos/theseer/fDOMDocument/zipball/6e8203e40a32a9c770bcb62fe37e68b948da6dca", + "reference": "6e8203e40a32a9c770bcb62fe37e68b948da6dca", "shasum": "" }, "require": { @@ -3508,7 +3668,7 @@ ], "description": "The classes contained within this repository extend the standard DOM to use exceptions at all occasions of errors instead of PHP warnings or notices. They also add various custom methods and shortcuts for convenience and to simplify the usage of DOM.", "homepage": "https://github.com/theseer/fDOMDocument", - "time": "2017-04-21T14:50:31+00:00" + "time": "2017-06-30T11:53:12+00:00" }, { "name": "theseer/tokenizer", @@ -3552,16 +3712,16 @@ }, { "name": "wapmorgan/php-code-analyzer", - "version": "1.0.3", + "version": "1.0.4", "source": { "type": "git", "url": "https://github.com/wapmorgan/PhpCodeAnalyzer.git", - "reference": "96b74840220b323c0cf59ae57f849701bc8cde19" + "reference": "7a8d7cb16ab9b0a33536320895eda66a4c3e9061" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/wapmorgan/PhpCodeAnalyzer/zipball/96b74840220b323c0cf59ae57f849701bc8cde19", - "reference": "96b74840220b323c0cf59ae57f849701bc8cde19", + "url": "https://api.github.com/repos/wapmorgan/PhpCodeAnalyzer/zipball/7a8d7cb16ab9b0a33536320895eda66a4c3e9061", + "reference": "7a8d7cb16ab9b0a33536320895eda66a4c3e9061", "shasum": "" }, "require": { @@ -3585,7 +3745,7 @@ "code analysis", "command-line utility" ], - "time": "2017-02-17T17:52:34+00:00" + "time": "2017-05-09T22:15:55+00:00" }, { "name": "webmozart/assert", diff --git a/src/Bytes.php b/src/Bytes.php new file mode 100644 index 0000000..748b73d --- /dev/null +++ b/src/Bytes.php @@ -0,0 +1,203 @@ + 'b', + self::KILOBYTES => 'kB', + self::KIBIBYTES => 'kiB', + self::MEGABYTES => 'MB', + self::MEBIBYTES => 'MiB', + self::GIGABYTES => 'GB', + self::GIBIBYTES => 'GiB', + self::TERABYTES => 'TB', + self::TEBIBYTES => 'TiB', + self::PETABYTES => 'PB', + self::PEBIBYTES => 'PiB', + self::EXABYTES => 'EB', + self::EXBIBYTES => 'EiB', + ]; + + /** + * Groupings of values determined by their base unit. + * + * @var array[] + */ + protected static $base = [ + 2 => [ + self::BYTES, + self::KIBIBYTES, + self::MEBIBYTES, + self::GIBIBYTES, + self::TEBIBYTES, + self::PEBIBYTES, + self::EXBIBYTES, + ], + 10 => [ + self::BYTES, + self::KILOBYTES, + self::MEGABYTES, + self::GIGABYTES, + self::TERABYTES, + self::PETABYTES, + self::EXABYTES, + ], + ]; + + /** + * Return human readable file sizes. + * + * @param int $bytes The number of bytes to format, as an integer. + * @param bool $useBase10 Whether or not to use `1000` for the base unit. A value of `true` means that `1000` + * will be used as the stepping unit. A value of `false` means that `1024` will be + * used as the stepping unit. + * @param int|null $base The base unit to lock to. By default, the base unit will increase as the values cross + * its threshold. If a value is passed here (should be one of the constants, and the + * constant must be _Base 2_ or _Base 10_ -- matching the `$useBase10` value). The + * default value is `null`, which means that the base unit is _unlocked_. + * @param string $format The final value is formatted using `sprintf()`. This is the format that should be + * used. The default value is `%01.2f %s`. + * + * @return string + * + * @codingStandardsIgnoreStart + */ + public static function format( + int $bytes, + $useBase10 = true, + ?int $base = null, + string $format = '%01.2f %s' + ): string { + // @codingStandardsIgnoreEnd + + $units = $useBase10 + ? self::$base[10] + : self::$base[2]; + + // Do we have a base unit? + if ($base) { + // Make sure it's legit + if (!\array_search($base, $units, true)) { + throw new RuntimeException(\sprintf( + 'A base value of %s was used, which is not understood. Please use one of the class constants as ' + . 'a base value instead.', + $base + )); + } + + return \sprintf( + $format, + ($bytes / $base), + self::$notations[$base] + ); + } + + // Otherwise, figure out the appropriate base unit + while (\count($units) > 0) { + $base = \array_pop($units); + + if ($bytes >= $base) { + return \sprintf( + $format, + ($bytes / $base), + self::$notations[$base] + ); + } + } + + throw new RuntimeException((string) $bytes); + } + + /** + * Returns the Base 2 value of the stepping. + * + * * 0 = 0 + * * 1 = 1024 (kibi) + * * 2 = 1048576 (mebi) + * * 3 = 1073741824 (gibi) + * + * @param int $stepping The stepping to calculate the value for. + * + * @return int + */ + public static function base2(int $stepping): int + { + return 2 ** (10 * $stepping); + } + + /** + * Returns the Base 10 value of the stepping. + * + * * 0 = 0 + * * 1 = 1000 (kilo) + * * 2 = 1000000 (mega) + * * 3 = 1000000000 (giga) + * + * @param int $stepping The stepping to calculate the value for. + * + * @return int + */ + public static function base10(int $stepping): int + { + return 10 ** (3 * $stepping); + } +} diff --git a/src/QueryString.php b/src/QueryString.php index b21f3f7..acb991f 100644 --- a/src/QueryString.php +++ b/src/QueryString.php @@ -1,9 +1,7 @@ getUri(); - return sprintf('%s://%s%s%s%s', + return \sprintf( + '%s://%s%s%s%s', $uri->getScheme(), $uri->getHost(), $uri->getPath(), diff --git a/tests/Unit/AbstractTestCase.php b/tests/Unit/AbstractTestCase.php index d1dda4b..f846a68 100644 --- a/tests/Unit/AbstractTestCase.php +++ b/tests/Unit/AbstractTestCase.php @@ -1,8 +1,7 @@ assertEquals(Bytes::BYTE, 1); + + // Base 10 + $this->assertEquals(Bytes::KB, 1000); + $this->assertEquals(Bytes::KILOBYTE, 1000); + $this->assertEquals(Bytes::KILOBYTES, 1000); + $this->assertEquals(Bytes::MB, 1000000); + $this->assertEquals(Bytes::MEGABYTE, 1000000); + $this->assertEquals(Bytes::MEGABYTES, 1000000); + $this->assertEquals(Bytes::GB, 1000000000); + $this->assertEquals(Bytes::GIGABYTE, 1000000000); + $this->assertEquals(Bytes::GIGABYTES, 1000000000); + $this->assertEquals(Bytes::TB, 1000000000000); + $this->assertEquals(Bytes::TERABYTE, 1000000000000); + $this->assertEquals(Bytes::TERABYTES, 1000000000000); + $this->assertEquals(Bytes::PB, 1000000000000000); + $this->assertEquals(Bytes::PETABYTE, 1000000000000000); + $this->assertEquals(Bytes::PETABYTES, 1000000000000000); + $this->assertEquals(Bytes::EB, 1000000000000000000); + $this->assertEquals(Bytes::EXABYTE, 1000000000000000000); + $this->assertEquals(Bytes::EXABYTES, 1000000000000000000); + + // Base 2 + $this->assertEquals(Bytes::KIB, 1024); + $this->assertEquals(Bytes::KIBIBYTE, 1024); + $this->assertEquals(Bytes::KIBIBYTES, 1024); + $this->assertEquals(Bytes::MIB, 1048576); + $this->assertEquals(Bytes::MEBIBYTE, 1048576); + $this->assertEquals(Bytes::MEBIBYTES, 1048576); + $this->assertEquals(Bytes::GIB, 1073741824); + $this->assertEquals(Bytes::GIBIBYTE, 1073741824); + $this->assertEquals(Bytes::GIBIBYTES, 1073741824); + $this->assertEquals(Bytes::TIB, 1099511627776); + $this->assertEquals(Bytes::TEBIBYTE, 1099511627776); + $this->assertEquals(Bytes::TEBIBYTES, 1099511627776); + $this->assertEquals(Bytes::PIB, 1125899906842624); + $this->assertEquals(Bytes::PEBIBYTE, 1125899906842624); + $this->assertEquals(Bytes::PEBIBYTES, 1125899906842624); + $this->assertEquals(Bytes::EIB, 1152921504606846976); + $this->assertEquals(Bytes::EXBIBYTE, 1152921504606846976); + $this->assertEquals(Bytes::EXBIBYTES, 1152921504606846976); + } + + public function testOtherByteValues(): void + { + $this->assertEquals(0.99 * Bytes::EXABYTES, 990000000000000000); + } + + public function testBase2(): void + { + $this->assertEquals(Bytes::base2(0), Bytes::BYTES); + $this->assertEquals(Bytes::base2(1), Bytes::KIBIBYTES); + $this->assertEquals(Bytes::base2(2), Bytes::MEBIBYTES); + $this->assertEquals(Bytes::base2(3), Bytes::GIBIBYTES); + $this->assertEquals(Bytes::base2(4), Bytes::TEBIBYTES); + $this->assertEquals(Bytes::base2(5), Bytes::PEBIBYTES); + $this->assertEquals(Bytes::base2(6), Bytes::EXBIBYTES); + } + + public function testBase10(): void + { + $this->assertEquals(Bytes::base10(0), Bytes::BYTES); + $this->assertEquals(Bytes::base10(1), Bytes::KILOBYTES); + $this->assertEquals(Bytes::base10(2), Bytes::MEGABYTES); + $this->assertEquals(Bytes::base10(3), Bytes::GIGABYTES); + $this->assertEquals(Bytes::base10(4), Bytes::TERABYTES); + $this->assertEquals(Bytes::base10(5), Bytes::PETABYTES); + $this->assertEquals(Bytes::base10(6), Bytes::EXABYTES); + } + + public function testFormatBase2Auto(): void + { + $this->assertEquals(Bytes::format(2 * Bytes::EXBIBYTES, false), '2.00 EiB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXBIBYTE, false), '1.00 EiB'); + + $this->assertEquals(Bytes::format(999 * Bytes::PEBIBYTES, false), '999.00 PiB'); + $this->assertEquals(Bytes::format(2 * Bytes::PEBIBYTES, false), '2.00 PiB'); + $this->assertEquals(Bytes::format(1 * Bytes::PEBIBYTE, false), '1.00 PiB'); + + $this->assertEquals(Bytes::format(999 * Bytes::TEBIBYTES, false), '999.00 TiB'); + $this->assertEquals(Bytes::format(2 * Bytes::TEBIBYTES, false), '2.00 TiB'); + $this->assertEquals(Bytes::format(1 * Bytes::TEBIBYTE, false), '1.00 TiB'); + } + + public function testFormatBase10Auto(): void + { + $this->assertEquals(Bytes::format(2 * Bytes::EXABYTES), '2.00 EB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXABYTE), '1.00 EB'); + $this->assertEquals(Bytes::format(990000000000000000), '990.00 PB'); + + $this->assertEquals(Bytes::format(999 * Bytes::PETABYTES), '999.00 PB'); + $this->assertEquals(Bytes::format(2 * Bytes::PETABYTES), '2.00 PB'); + $this->assertEquals(Bytes::format(1 * Bytes::PETABYTE), '1.00 PB'); + $this->assertEquals(Bytes::format(990000000000000), '990.00 TB'); + + $this->assertEquals(Bytes::format(999 * Bytes::TERABYTES), '999.00 TB'); + $this->assertEquals(Bytes::format(2 * Bytes::TERABYTES), '2.00 TB'); + $this->assertEquals(Bytes::format(1 * Bytes::TERABYTE), '1.00 TB'); + $this->assertEquals(Bytes::format(990000000000), '990.00 GB'); + } + + public function testFormatBaseLock(): void + { + $this->assertEquals(Bytes::format(1 * Bytes::EXABYTE), '1.00 EB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXABYTE, true, Bytes::EXABYTE), '1.00 EB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXABYTE, true, Bytes::PETABYTE), '1000.00 PB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXABYTE, true, Bytes::TERABYTE), '1000000.00 TB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXABYTE, true, Bytes::GIGABYTE), '1000000000.00 GB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXABYTE, true, Bytes::MEGABYTE), '1000000000000.00 MB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXABYTE, true, Bytes::KILOBYTE), '1000000000000000.00 kB'); + + $this->assertEquals(Bytes::format(1 * Bytes::EXBIBYTE), '1.15 EB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXBIBYTE, false), '1.00 EiB'); + + $this->assertEquals(Bytes::format(1 * Bytes::EXBIBYTE, true, Bytes::EXABYTE), '1.15 EB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXBIBYTE, true, Bytes::PETABYTE), '1152.92 PB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXBIBYTE, true, Bytes::TERABYTE), '1152921.50 TB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXBIBYTE, true, Bytes::GIGABYTE), '1152921504.61 GB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXBIBYTE, true, Bytes::MEGABYTE), '1152921504606.85 MB'); + $this->assertEquals(Bytes::format(1 * Bytes::EXBIBYTE, true, Bytes::KILOBYTE), '1152921504606847.00 kB'); + } +} diff --git a/tests/Unit/UtilityPack/QueryStringTest.php b/tests/Unit/UtilityPack/QueryStringTest.php index e58f426..48f267e 100644 --- a/tests/Unit/UtilityPack/QueryStringTest.php +++ b/tests/Unit/UtilityPack/QueryStringTest.php @@ -1,8 +1,7 @@ assertEquals('limit=a', QueryString::build([ 'limit' => 'a', diff --git a/tests/Unit/UtilityPack/TimeTest.php b/tests/Unit/UtilityPack/TimeTest.php index ccd2ec9..5d8b946 100644 --- a/tests/Unit/UtilityPack/TimeTest.php +++ b/tests/Unit/UtilityPack/TimeTest.php @@ -1,8 +1,7 @@ assertEquals(1, 1 * Time::SECOND); @@ -42,8 +44,8 @@ public function testTimeCalc() $this->assertEquals(1814400, 3 * Time::WEEKS); } - public function testDayCalc() + public function testDayCalc(): void { - $this->assertEquals('DateTime', get_class(Time::now())); + $this->assertEquals('DateTime', \get_class(Time::now())); } } diff --git a/tests/Unit/UtilityPack/TypeTest.php b/tests/Unit/UtilityPack/TypeTest.php index 0b4480c..3719d84 100644 --- a/tests/Unit/UtilityPack/TypeTest.php +++ b/tests/Unit/UtilityPack/TypeTest.php @@ -1,8 +1,7 @@ assertEquals('SimpleXMLElement', Types::getClassOrType( new \SimpleXMLElement('') diff --git a/tests/Unit/UtilityPack/UrlTest.php b/tests/Unit/UtilityPack/UrlTest.php index 84aa97f..ea684c9 100644 --- a/tests/Unit/UtilityPack/UrlTest.php +++ b/tests/Unit/UtilityPack/UrlTest.php @@ -1,8 +1,7 @@ false, - 'HTTP_HOST' => 'example.org', - 'SERVER_PORT' => 80, - 'REQUEST_URI' => '/testing', - 'QUERY_STRING' => 'qsa=asq', + 'HTTPS' => false, + 'HTTP_HOST' => 'example.org', + 'SERVER_PORT' => 80, + 'REQUEST_URI' => '/testing', + 'QUERY_STRING' => 'qsa=asq', ])); $this->assertEquals('http://example.org/testing?qsa=asq', Url::getCompleteUrl($request)); } - public function testUrlWith443() + public function testUrlWith443(): void { $request = Request::createFromEnvironment(Environment::mock([ - 'HTTPS' => true, - 'HTTP_HOST' => 'example.org', - 'SERVER_PORT' => 443, - 'REQUEST_URI' => '/testing', - 'QUERY_STRING' => 'qsa=asq', + 'HTTPS' => true, + 'HTTP_HOST' => 'example.org', + 'SERVER_PORT' => 443, + 'REQUEST_URI' => '/testing', + 'QUERY_STRING' => 'qsa=asq', ])); $this->assertEquals('https://example.org/testing?qsa=asq', Url::getCompleteUrl($request)); } - public function testUrlWith22() + public function testUrlWith22(): void { $request = Request::createFromEnvironment(Environment::mock([ - 'HTTPS' => false, - 'HTTP_HOST' => 'example.com', - 'SERVER_PORT' => 22, - 'REQUEST_URI' => '/testing', - 'QUERY_STRING' => 'qsa=asq', + 'HTTPS' => false, + 'HTTP_HOST' => 'example.com', + 'SERVER_PORT' => 22, + 'REQUEST_URI' => '/testing', + 'QUERY_STRING' => 'qsa=asq', ])); $this->assertEquals('http://example.com/testing?qsa=asq', Url::getCompleteUrl($request)); } - public function testUrlWith22NoQsa() + public function testUrlWith22NoQsa(): void { $request = Request::createFromEnvironment(Environment::mock([ - 'HTTPS' => false, - 'HTTP_HOST' => 'example.com', - 'SERVER_PORT' => 22, - 'REQUEST_URI' => '/testing', + 'HTTPS' => false, + 'HTTP_HOST' => 'example.com', + 'SERVER_PORT' => 22, + 'REQUEST_URI' => '/testing', ])); $this->assertEquals('http://example.com/testing', Url::getCompleteUrl($request)); } - public function testUrlWith22NoQsaNoPath() + public function testUrlWith22NoQsaNoPath(): void { $request = Request::createFromEnvironment(Environment::mock([ - 'HTTPS' => false, - 'HTTP_HOST' => 'example.com', - 'SERVER_PORT' => 22, + 'HTTPS' => false, + 'HTTP_HOST' => 'example.com', + 'SERVER_PORT' => 22, ])); $this->assertEquals('http://example.com/', Url::getCompleteUrl($request)); } - public function testUrlWith80NoQsaNoPath() + public function testUrlWith80NoQsaNoPath(): void { $request = Request::createFromEnvironment(Environment::mock([ - 'HTTPS' => false, - 'HTTP_HOST' => 'example.com', - 'SERVER_PORT' => 80, + 'HTTPS' => false, + 'HTTP_HOST' => 'example.com', + 'SERVER_PORT' => 80, ])); $this->assertEquals('http://example.com/', Url::getCompleteUrl($request)); } - public function testUrlWith80NoQsaNoPathNoPort() + public function testUrlWith80NoQsaNoPathNoPort(): void { $request = Request::createFromEnvironment(Environment::mock([ - 'HTTPS' => false, - 'HTTP_HOST' => 'example.com', + 'HTTPS' => false, + 'HTTP_HOST' => 'example.com', ])); $this->assertEquals('http://example.com/', Url::getCompleteUrl($request)); diff --git a/tests/bootstrap.php b/tests/bootstrap.php index e657d49..70cb4d7 100644 --- a/tests/bootstrap.php +++ b/tests/bootstrap.php @@ -1,12 +1,11 @@