Page MenuHomeDevCentral

No OneTemporary

diff --git a/.phan/config.php b/.phan/config.php
index 08b098f..588cf7b 100644
--- a/.phan/config.php
+++ b/.phan/config.php
@@ -1,259 +1,259 @@
<?php
use Phan\Issue;
return [
'target_php_version' => '7.2',
// If enabled, missing properties will be created when
// they are first seen. If false, we'll report an
// error message if there is an attempt to write
// to a class property that wasn't explicitly
// defined.
'allow_missing_properties' => false,
// If enabled, null can be cast as any type and any
// type can be cast to null. Setting this to true
// will cut down on false positives.
'null_casts_as_any_type' => false,
// If enabled, allow null to be cast as any array-like type.
// This is an incremental step in migrating away from null_casts_as_any_type.
// If null_casts_as_any_type is true, this has no effect.
'null_casts_as_array' => true,
// If enabled, allow any array-like type to be cast to null.
// This is an incremental step in migrating away from null_casts_as_any_type.
// If null_casts_as_any_type is true, this has no effect.
'array_casts_as_null' => true,
// If enabled, scalars (int, float, bool, string, null)
// are treated as if they can cast to each other.
// This does not affect checks of array keys. See scalar_array_key_cast.
'scalar_implicit_cast' => false,
// If enabled, any scalar array keys (int, string)
// are treated as if they can cast to each other.
// E.g. array<int,stdClass> can cast to array<string,stdClass> and vice versa.
// Normally, a scalar type such as int could only cast to/from int and mixed.
'scalar_array_key_cast' => true,
// If this has entries, scalars (int, float, bool, string, null)
// are allowed to perform the casts listed.
// E.g. ['int' => ['float', 'string'], 'float' => ['int'], 'string' => ['int'], 'null' => ['string']]
// allows casting null to a string, but not vice versa.
// (subset of scalar_implicit_cast)
'scalar_implicit_partial' => [],
// If true, seemingly undeclared variables in the global
// scope will be ignored. This is useful for projects
// with complicated cross-file globals that you have no
// hope of fixing.
'ignore_undeclared_variables_in_global_scope' => true,
// Set this to false to emit PhanUndeclaredFunction issues for internal functions that Phan has signatures for,
// but aren't available in the codebase, or the internal functions used to run phan
// (may lead to false positives if an extension isn't loaded)
// If this is true(default), then Phan will not warn.
'ignore_undeclared_functions_with_known_signatures' => true,
// Backwards Compatibility Checking. This is slow
// and expensive, but you should consider running
// it before upgrading your version of PHP to a
// new version that has backward compatibility
// breaks.
'backward_compatibility_checks' => false,
// If true, check to make sure the return type declared
// in the doc-block (if any) matches the return type
// declared in the method signature.
'check_docblock_signature_return_type_match' => false,
// (*Requires check_docblock_signature_param_type_match to be true*)
// If true, make narrowed types from phpdoc params override
// the real types from the signature, when real types exist.
// (E.g. allows specifying desired lists of subclasses,
// or to indicate a preference for non-nullable types over nullable types)
// Affects analysis of the body of the method and the param types passed in by callers.
'prefer_narrowed_phpdoc_param_type' => true,
// (*Requires check_docblock_signature_return_type_match to be true*)
// If true, make narrowed types from phpdoc returns override
// the real types from the signature, when real types exist.
// (E.g. allows specifying desired lists of subclasses,
// or to indicate a preference for non-nullable types over nullable types)
// Affects analysis of return statements in the body of the method and the return types passed in by callers.
'prefer_narrowed_phpdoc_return_type' => true,
// If enabled, check all methods that override a
// parent method to make sure its signature is
// compatible with the parent's. This check
// can add quite a bit of time to the analysis.
// This will also check if final methods are overridden, etc.
'analyze_signature_compatibility' => true,
// This setting maps case insensitive strings to union types.
// This is useful if a project uses phpdoc that differs from the phpdoc2 standard.
// If the corresponding value is the empty string, Phan will ignore that union type (E.g. can ignore 'the' in `@return the value`)
// If the corresponding value is not empty, Phan will act as though it saw the corresponding unionTypes(s) when the keys show up in a UnionType of @param, @return, @var, @property, etc.
//
// This matches the **entire string**, not parts of the string.
// (E.g. `@return the|null` will still look for a class with the name `the`, but `@return the` will be ignored with the below setting)
//
// (These are not aliases, this setting is ignored outside of doc comments).
// (Phan does not check if classes with these names exist)
//
// Example setting: ['unknown' => '', 'number' => 'int|float', 'char' => 'string', 'long' => 'int', 'the' => '']
'phpdoc_type_mapping' => [],
// Set to true in order to attempt to detect dead
// (unreferenced) code. Keep in mind that the
// results will only be a guess given that classes,
// properties, constants and methods can be referenced
// as variables (like `$class->$property` or
// `$class->$method()`) in ways that we're unable
// to make sense of.
'dead_code_detection' => false,
// If true, this run a quick version of checks that takes less
// time at the cost of not running as thorough
// an analysis. You should consider setting this
// to true only when you wish you had more **undiagnosed** issues
// to fix in your code base.
//
// In quick-mode the scanner doesn't rescan a function
// or a method's code block every time a call is seen.
// This means that the problem here won't be detected:
//
// ```php
// <?php
// function test($arg):int {
// return $arg;
// }
// test("abc");
// ```
//
// This would normally generate:
//
// ```sh
// test.php:3 TypeError return string but `test()` is declared to return int
// ```
//
// The initial scan of the function's code block has no
// type information for `$arg`. It isn't until we see
// the call and rescan test()'s code block that we can
// detect that it is actually returning the passed in
// `string` instead of an `int` as declared.
'quick_mode' => false,
// If true, then before analysis, try to simplify AST into a form
// which improves Phan's type inference in edge cases.
//
// This may conflict with 'dead_code_detection'.
// When this is true, this slows down analysis slightly.
//
// E.g. rewrites `if ($a = value() && $a > 0) {...}`
// into $a = value(); if ($a) { if ($a > 0) {...}}`
'simplify_ast' => true,
// Enable or disable support for generic templated
// class types.
'generic_types_enabled' => true,
// Override to hardcode existence and types of (non-builtin) globals in the global scope.
// Class names should be prefixed with '\\'.
// (E.g. ['_FOO' => '\\FooClass', 'page' => '\\PageClass', 'userId' => 'int'])
'globals_type_map' => [],
// The minimum severity level to report on. This can be
// set to Issue::SEVERITY_LOW, Issue::SEVERITY_NORMAL or
// Issue::SEVERITY_CRITICAL. Setting it to only
// critical issues is a good place to start on a big
// sloppy mature code base.
'minimum_severity' => Issue::SEVERITY_LOW,
// Add any issue types (such as 'PhanUndeclaredMethod')
// to this black-list to inhibit them from being reported.
'suppress_issue_types' => [],
// A regular expression to match files to be excluded
// from parsing and analysis and will not be read at all.
//
// This is useful for excluding groups of test or example
// directories/files, unanalyzable files, or files that
// can't be removed for whatever reason.
// (e.g. '@Test\.php$@', or '@vendor/.*/(tests|Tests)/@')
'exclude_file_regex' => '@^vendor/.*/(tests?|Tests?)/@',
// A file list that defines files that will be excluded
// from parsing and analysis and will not be read at all.
//
// This is useful for excluding hopelessly unanalyzable
// files that can't be removed for whatever reason.
'exclude_file_list' => [],
// A directory list that defines files that will be excluded
// from static analysis, but whose class and method
// information should be included.
//
// Generally, you'll want to include the directories for
// third-party code (such as "vendor/") in this list.
//
// n.b.: If you'd like to parse but not analyze 3rd
// party code, directories containing that code
// should be added to the `directory_list` as
- // to `excluce_analysis_directory_list`.
+ // to `exclude_analysis_directory_list`.
'exclude_analysis_directory_list' => [
'vendor/',
],
// The number of processes to fork off during the analysis
// phase.
'processes' => 1,
// List of case-insensitive file extensions supported by Phan.
// (e.g. php, html, htm)
'analyzed_file_extensions' => [
'php',
],
// You can put paths to stubs of internal extensions in this config option.
// If the corresponding extension is **not** loaded, then phan will use the stubs instead.
// Phan will continue using its detailed type annotations,
// but load the constants, classes, functions, and classes (and their Reflection types)
// from these stub files (doubling as valid php files).
// Use a different extension from php to avoid accidentally loading these.
// The 'tools/make_stubs' script can be used to generate your own stubs (compatible with php 7.0+ right now)
'autoload_internal_extension_signatures' => [],
// A list of plugin files to execute
// Plugins which are bundled with Phan can be added here by providing their name (e.g. 'AlwaysReturnPlugin')
// Alternately, you can pass in the full path to a PHP file with the plugin's implementation (e.g. 'vendor/phan/phan/.phan/plugins/AlwaysReturnPlugin.php')
'plugins' => [
'AlwaysReturnPlugin',
'PregRegexCheckerPlugin',
'UnreachableCodePlugin',
'WhitespacePlugin',
],
// A list of directories that should be parsed for class and
// method information. After excluding the directories
// defined in exclude_analysis_directory_list, the remaining
// files will be statically analyzed for errors.
//
// Thus, both first-party and third-party code being used by
// your application should be included in this list.
'directory_list' => [
'src',
'tests',
'vendor/phan/phan/src/Phan',
'vendor/phpunit/phpunit/src',
],
// A list of individual files to include in analysis
// with a path relative to the root directory of the
// project
'file_list' => [],
];
diff --git a/src/Culture/Rome/RomanNumerals.php b/src/Culture/Rome/RomanNumerals.php
index 2514750..7525ce9 100644
--- a/src/Culture/Rome/RomanNumerals.php
+++ b/src/Culture/Rome/RomanNumerals.php
@@ -1,96 +1,96 @@
<?php
declare(strict_types=1);
namespace Keruald\OmniTools\Culture\Rome;
use InvalidArgumentException;
final class RomanNumerals {
public static function fromHinduArabic (int $number) : string {
self::assertStrictlyPositiveNumber($number);
if ($number > 1000) {
return self::computeFromKiloHinduArabic($number);
}
$table = self::getHinduArabicTable();
return $table[$number] ?? self::computeFromHinduArabic($number);
}
/**
* Provides a canonical table with hindu arabic numerals as keys,
- * and roman numerals as values.
+ * and Roman numerals as values.
*/
public static function getHinduArabicTable () : array {
return [
1 => 'i',
2 => 'ii',
3 => 'iii',
4 => 'iv',
5 => 'v',
6 => 'vi',
7 => 'vii',
8 => 'viii',
9 => 'ix',
10 => 'x',
50 => 'l',
100 => 'c',
500 => 'd',
1000 => 'm',
];
}
private static function getComputeHinduArabicTable () : iterable {
// limit => number to subtract (as a [roman, hindu arabic] array)
yield 21 => ['x', 10];
yield 30 => ['xx', 20];
yield 40 => ['xxx', 30];
yield 50 => ['xl', 40];
yield 60 => ['l', 50];
yield 70 => ['lx', 60];
yield 80 => ['lxx', 70];
yield 90 => ['lxxx', 80];
yield 100 => ['xc', 90];
yield 200 => ['c', 100];
yield 300 => ['cc', 200];
yield 400 => ['ccc', 300];
yield 500 => ['cd', 400];
yield 600 => ['d', 500];
yield 700 => ['dc', 600];
yield 800 => ['dcc', 700];
yield 900 => ['dccc', 800];
yield 1000 => ['cm', 900];
}
private static function computeFromHinduArabic (int $number) : string {
foreach (self::getComputeHinduArabicTable() as $limit => $term) {
if ($number < $limit) {
return $term[0] . self::fromHinduArabic($number - $term[1]);
}
}
throw new \LogicException("This should be unreachable code.");
}
private static function computeFromKiloHinduArabic (int $number) : string {
$thousandAmount = (int)floor($number / 1000);
$remainder = $number % 1000;
$roman = str_repeat('m', $thousandAmount);
if ($remainder > 0) {
$roman .= self::fromHinduArabic($remainder);
}
return $roman;
}
private static function assertStrictlyPositiveNumber (int $number) : void {
if ($number < 1) {
throw new InvalidArgumentException(
"Can only convert strictly positive numbers"
);
}
}
}
diff --git a/src/HTTP/Requests/RemoteAddress.php b/src/HTTP/Requests/RemoteAddress.php
index d25084b..4558223 100644
--- a/src/HTTP/Requests/RemoteAddress.php
+++ b/src/HTTP/Requests/RemoteAddress.php
@@ -1,94 +1,94 @@
<?php
declare(strict_types=1);
namespace Keruald\OmniTools\HTTP\Requests;
use Keruald\OmniTools\Network\IP;
class RemoteAddress {
/**
* @var string
*/
private $remoteAddress;
///
/// Constructor
///
public function __construct (string $remoteAddress = '') {
$this->remoteAddress = $remoteAddress;
}
public static function fromServer () : self {
return new self(self::extractRemoteAddressesFromHeaders());
}
///
/// Format methods
///
public function getClientAddress () : string {
// Header contains 'clientIP, proxyIP, anotherProxyIP'
// or 'clientIP proxyIP anotherProxyIP'
- // The first value is so the one to return.
+ // The client address to return is then the first value.
// See draft-ietf-appsawg-http-forwarded-10.
$ips = preg_split("/[\s,]+/", $this->remoteAddress, 2);
return trim($ips[0]);
}
public function isFromLocalHost () : bool {
return IP::isLoopBack($this->getClientAddress());
}
public function getAll () : string {
return $this->remoteAddress;
}
public function has () : bool {
return $this->remoteAddress !== "";
}
///
/// Information methods
///
///
/// Helper methods to determine the remote address
///
/**
* Allows to get all the remote addresses from relevant headers
*/
public static function extractRemoteAddressesFromHeaders () : string {
foreach (self::listRemoteAddressHeaders() as $candidate) {
if (isset($_SERVER[$candidate])) {
return $_SERVER[$candidate];
}
}
return "";
}
///
/// Data sources
///
public static function listRemoteAddressHeaders () : array {
return [
// Standard header provided by draft-ietf-appsawg-http-forwarded-10
'HTTP_X_FORWARDED_FOR',
// Legacy headers
'HTTP_CLIENT_IP',
'HTTP_FORWARDED',
'HTTP_FORWARDED_FOR',
'HTTP_X_CLUSTER_CLIENT_IP',
'HTTP_X_FORWARDED',
// Default header if no proxy information could be detected
'REMOTE_ADDR',
];
}
}
diff --git a/src/Identifiers/UUID.php b/src/Identifiers/UUID.php
index 80626b7..2f05ac1 100644
--- a/src/Identifiers/UUID.php
+++ b/src/Identifiers/UUID.php
@@ -1,49 +1,49 @@
<?php
declare(strict_types=1);
namespace Keruald\OmniTools\Identifiers;
class UUID {
const UUID_REGEXP = "/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/";
/**
- * @return string A RFC 4122 compliant v4 UUID
+ * @return string An RFC 4122 compliant v4 UUID
*/
public static function UUIDv4 () : string {
// Code by Andrew Moore
// See http://php.net/manual/en/function.uniqid.php#94959
// https://www.ietf.org/rfc/rfc4122.txt
return sprintf(
'%04x%04x-%04x-%04x-%04x-%04x%04x%04x',
// 32 bits for "time_low"
mt_rand(0, 0xffff), mt_rand(0, 0xffff),
// 16 bits for "time_mid"
mt_rand(0, 0xffff),
// 16 bits for "time_hi_and_version",
// four most significant bits holds version number 4
mt_rand(0, 0x0fff) | 0x4000,
// 16 bits, 8 bits for "clk_seq_hi_res",
// 8 bits for "clk_seq_low",
// two most significant bits holds zero and one for variant DCE1.1
mt_rand(0, 0x3fff) | 0x8000,
// 48 bits for "node"
mt_rand(0, 0xffff), mt_rand(0, 0xffff), mt_rand(0, 0xffff)
);
}
public static function UUIDv4WithoutHyphens () : string {
return str_replace("-", "", self::UUIDv4());
}
public static function isUUID ($string) : bool {
return (bool)preg_match(self::UUID_REGEXP, $string);
}
}
diff --git a/src/OS/CurrentProcess.php b/src/OS/CurrentProcess.php
index 9d7870d..8e5740e 100644
--- a/src/OS/CurrentProcess.php
+++ b/src/OS/CurrentProcess.php
@@ -1,33 +1,33 @@
<?php
declare(strict_types=1);
namespace Keruald\OmniTools\OS;
class CurrentProcess {
/**
* Determines if the current process, ie the PHP interpreter,
* runs as root on UNIX systems or in elevated mode on Windows.
*
* Cygwin processes are considered as Windows processes.
*/
public static function isPrivileged () : bool {
if (CurrentOS::isWindows()) {
// `net session` is known to only work as privileged process.
- // To wrap in cmd allows to avoid /dev/null for Cygwin,
+ // To wrap in cmd allows avoiding /dev/null for Cygwin,
// or $null when invoked from PowerShell. NUL: will always be used.
exec('cmd /C "net session >NUL 2>&1"', $_, $exitCode);
return $exitCode === 0;
}
if (!function_exists('posix_geteuid')) {
// POSIX PHP functions aren't always available, e.g. on FreeBSD
// In such cases, `id` will probably be available.
return trim((string)shell_exec('id -u')) === '0';
}
return posix_geteuid() === 0;
}
}
diff --git a/src/Strings/Multibyte/StringUtilities.php b/src/Strings/Multibyte/StringUtilities.php
index 2dbf319..dd57d92 100644
--- a/src/Strings/Multibyte/StringUtilities.php
+++ b/src/Strings/Multibyte/StringUtilities.php
@@ -1,88 +1,88 @@
<?php
declare(strict_types=1);
namespace Keruald\OmniTools\Strings\Multibyte;
class StringUtilities {
/**
* Pads a multibyte string to a certain length with another string
*
* @param string $input the input string
* @param int $padLength the target string size
* @param string $padString the padding characters (optional, default is space)
* @param int $padType STR_PAD_RIGHT, STR_PAD_LEFT, or STR_PAD_BOTH (optional, default is STR_PAD_RIGHT)
* @param string $encoding the character encoding (optional)
*
* @return string the padded string
*
*/
public static function pad (
string $input,
int $padLength,
string $padString = ' ',
int $padType = STR_PAD_RIGHT,
string $encoding = ''
) : string {
return (new StringPad)
->setInput($input)
->setPadLength($padLength)
->setPadString($padString)
->setPadType($padType)
->setEncoding($encoding ?: mb_internal_encoding())
->pad();
}
public static function isSupportedEncoding (string $encoding) : bool {
foreach (mb_list_encodings() as $supportedEncoding) {
if ($encoding === $supportedEncoding) {
return true;
}
}
return false;
}
public static function startsWith (string $string, string $start) {
$length = mb_strlen($start);
return mb_substr($string, 0, $length) === $start;
}
public static function endsWith (string $string, string $end) {
$length = mb_strlen($end);
return $length === 0 || mb_substr($string, -$length) === $end;
}
public static function contains (string $string, string $needle) : bool {
return strpos($string, $needle) !== false;
}
/**
* Encode a string using a variant of the MIME base64 compatible with URLs.
*
- * The + and / characters used in base64 are replaced by - and _.
- * The = padding is removed.
+ * The '+' and '/' characters used in base64 are replaced by '-' and '_'.
+ * The '=' padding is removed.
*
* @param string $string The string to encode
* @return string The encoded string
*/
public static function encodeInBase64 (string $string) : string {
return str_replace(
['+', '/', '='],
['-', '_', ''],
base64_encode($string)
);
}
/**
* Decode a string encoded with StringUtilities::encodeInBase64
*
* @param string $string The string to decode
* @return string The decoded string
*/
public static function decodeFromBase64 (string $string) : string {
$toDecode = str_replace(['-', '_'], ['+', '/'], $string);
return base64_decode($toDecode);
}
}
diff --git a/tests/Network/IPTest.php b/tests/Network/IPTest.php
index bc88636..e1b3b4e 100644
--- a/tests/Network/IPTest.php
+++ b/tests/Network/IPTest.php
@@ -1,148 +1,148 @@
<?php
declare(strict_types=1);
namespace Keruald\OmniTools\Tests\Network;
use Keruald\OmniTools\Network\IP;
use PHPUnit\Framework\TestCase;
class IPTest extends TestCase {
///
/// Data providers for IP addresses
///
- /// These data providers methods allow to provide IP addresses
+ /// These data providers methods allow providing IP addresses
/// to validate or invalidate.
///
/// The advanced IPv6 tests have been curated by Stephen Ryan
/// Source: https://web.archive.org/web/20110515134717/http://forums.dartware.com/viewtopic.php?t=452
///
public function provideValidIP () : iterable {
yield ["0.0.0.0"];
yield ["17.17.17.17"];
yield ["fe80:0000:0000:0000:0204:61ff:fe9d:f156"];
}
public function provideInvalidIP () : iterable {
yield [""];
yield ["1"];
yield ["17.17"];
yield ["17.17.17.256"];
}
public function provideValidIPv4 () : iterable {
return [["0.0.0.0"], ["17.17.17.17"]];
}
public function provideInvalidIPv4 () : iterable {
yield [""];
yield ["1"];
yield ["17.17"];
yield ["17.17.17.256"];
yield ["fe80:0000:0000:0000:0204:61ff:fe9d:f156"];
}
public function provideValidIPv6 () : iterable {
yield ["::1"];
yield ["::ffff:192.0.2.128"];
yield ["fe80:0000:0000:0000:0204:61ff:fe9d:f156"];
yield ["::ffff:192.0.2.128", "IPv4 represented as dotted-quads"];
}
public function provideInvalidIPv6 () : iterable {
yield ["0.0.0.0"];
yield [""];
yield ["1"];
yield ["17.17"];
yield ["17.17.17.17"];
yield ["::fg", "Valid IPv6 digits are 0-f, ie 0-9 and a-f"];
yield ["02001:0000:1234:0000:0000:C1C0:ABCD:0876", "Extra 0"];
yield ["2001:0000:1234:0000:00001:C1C0:ABCD:0876", "Extra 0"];
yield ["1.2.3.4:1111:2222:3333:4444::5555"];
}
public function provideValidLoopbackIP () : iterable {
yield ["127.0.0.1"];
yield ["127.0.0.3"];
yield ["::1"];
}
public function provideInvalidLoopbackIP () : iterable {
yield ["0.0.0.0"];
yield ["1.2.3.4"];
yield ["192.168.1.1"];
yield ["::2"];
}
///
/// Test cases
///
/**
* @covers \Keruald\OmniTools\Network\IP::isIP
* @dataProvider provideValidIP
*/
public function testIsIP ($ip) {
$this->assertTrue(IP::isIP($ip));
}
/**
* @covers \Keruald\OmniTools\Network\IP::isIP
* @dataProvider provideInvalidIP
*/
public function testIsIPWhenItIsNot ($ip) {
$this->assertFalse(IP::isIP($ip));
}
/**
* @covers \Keruald\OmniTools\Network\IP::isIPv4
* @dataProvider provideValidIPv4
*/
public function testIsIPv4 ($ip) {
$this->assertTrue(IP::isIPv4($ip));
}
/**
* @covers \Keruald\OmniTools\Network\IP::isIPv4
* @dataProvider provideInvalidIPv4
*/
public function testIsIPv4WhenItIsNot ($ip) {
$this->assertFalse(IP::isIPv4($ip));
}
/**
* @covers \Keruald\OmniTools\Network\IP::isIPv6
* @dataProvider provideValidIPv6
*/
public function testIsIPv6 (string $ip, string $message = "") {
$this->assertTrue(IP::isIPv6($ip), $message);
}
/**
* @covers \Keruald\OmniTools\Network\IP::isIPv6
* @dataProvider provideInvalidIPv6
*/
public function testIsIPv6WhenItIsNot (string $ip, string $message = "") : void {
$this->assertFalse(IP::isIPv6($ip), $message);
}
/**
* @covers \Keruald\OmniTools\Network\IP::isLoopback
* @dataProvider provideValidLoopbackIP
*/
public function testIsLoopback (string $ip) : void {
$this->assertTrue(IP::isLoopback($ip));
}
/**
* @covers \Keruald\OmniTools\Network\IP::isLoopback
* @dataProvider provideInvalidLoopbackIP
*/
public function testIsLoopbackWhenItIsNot (string $ip) : void {
$this->assertFalse(IP::isLoopback($ip));
}
}
diff --git a/tests/data/MockLib/Bar.php b/tests/data/MockLib/Bar.php
index 797ef08..55f803b 100644
--- a/tests/data/MockLib/Bar.php
+++ b/tests/data/MockLib/Bar.php
@@ -1,15 +1,15 @@
<?php
namespace Acme\MockLib;
/**
* Class Bar
*
- * This class allows to check if the autoloader can register
+ * This class allows checking if the autoloader can register
* the Acme\MockLib namespace and include this file.
*
* @package Acme\MockLib
*/
class Bar {
}
diff --git a/tests/data/MockLib/Foo.php b/tests/data/MockLib/Foo.php
index cd1b3fa..c33d6a6 100644
--- a/tests/data/MockLib/Foo.php
+++ b/tests/data/MockLib/Foo.php
@@ -1,15 +1,15 @@
<?php
namespace Acme\MockLib;
/**
* Class Foo
*
- * This class allows to check if the autoloader can register
+ * This class allows checking if the autoloader can register
* the Acme\MockLib namespace and include this file.
*
* @package Acme\MockLib
*/
class Foo {
}

File Metadata

Mime Type
text/x-diff
Expires
Mon, Nov 25, 15:05 (1 d, 4 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2260439
Default Alt Text
(28 KB)

Event Timeline