Skip to content

Commit

Permalink
Merge ca79ab4 into b563caf
Browse files Browse the repository at this point in the history
  • Loading branch information
bizurkur committed Feb 17, 2020
2 parents b563caf + ca79ab4 commit 0cb695e
Show file tree
Hide file tree
Showing 99 changed files with 692 additions and 175 deletions.
10 changes: 6 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
2.0.0 (20??-??-??)
------------------

* Add inode support
* Add inode support
* Namespace changed from `org\bovigo\vfs` to `bovigo\vfs`
- The old namespace will still work, but has been deprecated. It will be removed in version 3.

### BC breaks

* raised minimum required PHP version to 7.2.0
* all methods of `org\bovigo\vfs\visitor\vfsStreamVisitor` are now declared with `self` as return type
* `vfsStreamWrapper::setRoot()` and `vsfStreamWrapper::getRoot()` method signatures now require and return `org\bovigo\vfs\vfsStreamDirectory` vice `org\bovigo\vfs\vfsStreamContainer`.
* `vfsStream::newFile()`, `vfsStream::newBlock()`, `org\bovigo\vfs\vfsStreamFile`, and `org\bovigo\vfs\vfsStreamBlock` will throw an exception if the filename contains a forward slash (`/`).
* all methods of `bovigo\vfs\visitor\vfsStreamVisitor` are now declared with `self` as return type
* `vfsStreamWrapper::setRoot()` and `vsfStreamWrapper::getRoot()` method signatures now require and return `bovigo\vfs\vfsStreamDirectory` vice `bovigo\vfs\vfsStreamContainer`.
* `vfsStream::newFile()`, `vfsStream::newBlock()`, `bovigo\vfs\vfsStreamFile`, and `bovigo\vfs\vfsStreamBlock` will throw an exception if the filename contains a forward slash (`/`).

1.6.8 (2019-10-30)
------------------
Expand Down
9 changes: 7 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,15 @@
"doctrine/coding-standard": "^6.0"
},
"autoload": {
"psr-4": { "org\\bovigo\\vfs\\": "src/main/php/org/bovigo/vfs" }
"psr-4": {
"bovigo\\vfs\\": "src",
"org\\bovigo\\vfs\\": "org/bovigo/vfs"
}
},
"autoload-dev": {
"psr-4": { "org\\bovigo\\vfs\\": "src/test/php/org/bovigo/vfs" }
"psr-4": {
"bovigo\\vfs\\Tests\\": "tests/phpunit"
}
},
"extra": {
"branch-alias": {
Expand Down
6 changes: 3 additions & 3 deletions examples/Example.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @package org\bovigo\vfs
* @package bovigo\vfs
*/
namespace org\bovigo\vfs\example;
namespace bovigo\vfs\example;
/**
* Example class.
*/
Expand Down Expand Up @@ -51,4 +51,4 @@ public function setDirectory($directory)

// more source code here...
}
?>
?>
6 changes: 3 additions & 3 deletions examples/ExampleTestCaseOldWay.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @package org\bovigo\vfs
* @package bovigo\vfs
*/
namespace org\bovigo\vfs\example;
namespace bovigo\vfs\example;
require_once 'Example.php';
/**
* Test case for class Example.
Expand Down Expand Up @@ -45,4 +45,4 @@ public function directoryIsCreated()
$this->assertTrue(file_exists(__DIR__ . '/id'));
}
}
?>
?>
8 changes: 4 additions & 4 deletions examples/ExampleTestCaseWithVfsStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @package org\bovigo\vfs
* @package bovigo\vfs
*/
namespace org\bovigo\vfs\example;
use org\bovigo\vfs\vfsStream;
namespace bovigo\vfs\example;
use bovigo\vfs\vfsStream;
require_once 'Example.php';
/**
* Test case for class Example.
Expand Down Expand Up @@ -44,4 +44,4 @@ public function directoryIsCreated()
$this->assertTrue($this->root->hasChild('id'));
}
}
?>
?>
6 changes: 3 additions & 3 deletions examples/FailureExample.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @package org\bovigo\vfs
* @package bovigo\vfs
*/
namespace org\bovigo\vfs\example;
namespace bovigo\vfs\example;
/**
* Example class to demonstrate testing of failure behaviour with vfsStream.
*/
Expand Down Expand Up @@ -47,4 +47,4 @@ public function writeData($data)

// more source code here...
}
?>
?>
8 changes: 4 additions & 4 deletions examples/FailureExampleTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @package org\bovigo\vfs
* @package bovigo\vfs
*/
namespace org\bovigo\vfs\example;
use org\bovigo\vfs\vfsStream;
namespace bovigo\vfs\example;
use bovigo\vfs\vfsStream;
require_once 'FailureExample.php';
/**
* Test case for class FailureExample.
Expand Down Expand Up @@ -55,4 +55,4 @@ public function returnsErrorMessageIfWritingToFileFails()
$this->assertSame('notoverwritten', $this->root->getChild('test.txt')->getContent());
}
}
?>
?>
6 changes: 3 additions & 3 deletions examples/FileModeExampleTestCaseOldWay.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @package org\bovigo\vfs
* @package bovigo\vfs
*/
namespace org\bovigo\vfs\example;
namespace bovigo\vfs\example;
require_once 'FilemodeExample.php';
/**
* Test case for class FilemodeExample.
Expand Down Expand Up @@ -64,4 +64,4 @@ public function testDirectoryHasCorrectDifferentFilePermissions()
}
}
}
?>
?>
6 changes: 3 additions & 3 deletions examples/FilePermissionsExample.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @package org\bovigo\vfs
* @package bovigo\vfs
*/
namespace org\bovigo\vfs\example;
namespace bovigo\vfs\example;
/**
* Example showing correct file permission support introduced with 0.7.0.
*/
Expand All @@ -26,4 +26,4 @@ public function writeConfig($config, $configFile)

// more methods here
}
?>
?>
8 changes: 4 additions & 4 deletions examples/FilePermissionsExampleTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @package org\bovigo\vfs
* @package bovigo\vfs
*/
namespace org\bovigo\vfs\example;
use org\bovigo\vfs\vfsStream;
namespace bovigo\vfs\example;
use bovigo\vfs\vfsStream;
require_once 'FilePermissionsExample.php';
/**
* Test for FilePermissionsExample.
Expand Down Expand Up @@ -41,4 +41,4 @@ public function directoryNotWritable()
);
}
}
?>
?>
6 changes: 3 additions & 3 deletions examples/FilemodeExample.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @package org\bovigo\vfs
* @package bovigo\vfs
*/
namespace org\bovigo\vfs\example;
namespace bovigo\vfs\example;
/**
* Example class.
*/
Expand Down Expand Up @@ -59,4 +59,4 @@ public function setDirectory($directory)

// more source code here...
}
?>
?>
8 changes: 4 additions & 4 deletions examples/FilemodeExampleTestCaseWithVfsStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @package org\bovigo\vfs
* @package bovigo\vfs
*/
namespace org\bovigo\vfs\example;
use org\bovigo\vfs\vfsStream;
namespace bovigo\vfs\example;
use bovigo\vfs\vfsStream;
require_once 'FilemodeExample.php';
/**
* Test case for class FilemodeExample.
Expand Down Expand Up @@ -50,4 +50,4 @@ public function testDirectoryIsCreatedWithGivenPermissions()
$this->assertEquals(0755, $this->root->getChild('id')->getPermissions());
}
}
?>
?>
18 changes: 18 additions & 0 deletions org/bovigo/vfs/DotDirectory.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

declare(strict_types=1);

namespace org\bovigo\vfs;

use bovigo\vfs\DotDirectory as Base;

class_exists('bovigo\vfs\DotDirectory');

@trigger_error('Using the "org\bovigo\vfs\DotDirectory" class is deprecated since version 2 and will be removed in version 3, use "bovigo\vfs\DotDirectory" instead.', E_USER_DEPRECATED);

if (\false) {
/** @deprecated since 2, use "bovigo\vfs\DotDirectory" instead */
class DotDirectory extends Base
{
}
}
18 changes: 18 additions & 0 deletions org/bovigo/vfs/Quota.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

declare(strict_types=1);

namespace org\bovigo\vfs;

use bovigo\vfs\Quota as Base;

class_exists('bovigo\vfs\Quota');

@trigger_error('Using the "org\bovigo\vfs\Quota" class is deprecated since version 2 and will be removed in version 3, use "bovigo\vfs\Quota" instead.', E_USER_DEPRECATED);

if (\false) {
/** @deprecated since 2, use "bovigo\vfs\Quota" instead */
class Quota extends Base
{
}
}
18 changes: 18 additions & 0 deletions org/bovigo/vfs/content/FileContent.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

declare(strict_types=1);

namespace org\bovigo\vfs\content;

use bovigo\vfs\content\FileContent as Base;

interface_exists('bovigo\vfs\content\FileContent');

@trigger_error('Using the "org\bovigo\vfs\content\FileContent" interface is deprecated since version 2 and will be removed in version 3, use "bovigo\vfs\content\FileContent" instead.', E_USER_DEPRECATED);

if (\false) {
/** @deprecated since 2, use "bovigo\vfs\FileContent" instead */
interface FileContent extends Base
{
}
}
18 changes: 18 additions & 0 deletions org/bovigo/vfs/content/LargeFileContent.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

declare(strict_types=1);

namespace org\bovigo\vfs\content;

use bovigo\vfs\content\LargeFileContent as Base;

class_exists('bovigo\vfs\content\LargeFileContent');

@trigger_error('Using the "org\bovigo\vfs\content\LargeFileContent" class is deprecated since version 2 and will be removed in version 3, use "bovigo\vfs\content\LargeFileContent" instead.', E_USER_DEPRECATED);

if (\false) {
/** @deprecated since 2, use "bovigo\vfs\LargeFileContent" instead */
class LargeFileContent extends Base
{
}
}
18 changes: 18 additions & 0 deletions org/bovigo/vfs/content/SeekableFileContent.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

declare(strict_types=1);

namespace org\bovigo\vfs\content;

use bovigo\vfs\content\SeekableFileContent as Base;

class_exists('bovigo\vfs\content\SeekableFileContent');

@trigger_error('Using the "org\bovigo\vfs\content\SeekableFileContent" class is deprecated since version 2 and will be removed in version 3, use "bovigo\vfs\content\SeekableFileContent" instead.', E_USER_DEPRECATED);

if (\false) {
/** @deprecated since 2, use "bovigo\vfs\SeekableFileContent" instead */
abstract class SeekableFileContent extends Base
{
}
}
18 changes: 18 additions & 0 deletions org/bovigo/vfs/content/StringBasedFileContent.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

declare(strict_types=1);

namespace org\bovigo\vfs\content;

use bovigo\vfs\content\StringBasedFileContent as Base;

class_exists('bovigo\vfs\content\StringBasedFileContent');

@trigger_error('Using the "org\bovigo\vfs\content\StringBasedFileContent" class is deprecated since version 2 and will be removed in version 3, use "bovigo\vfs\content\StringBasedFileContent" instead.', E_USER_DEPRECATED);

if (\false) {
/** @deprecated since 2, use "bovigo\vfs\StringBasedFileContent" instead */
class StringBasedFileContent extends Base
{
}
}
18 changes: 18 additions & 0 deletions org/bovigo/vfs/vfsStream.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

declare(strict_types=1);

namespace org\bovigo\vfs;

use bovigo\vfs\vfsStream as Base;

class_exists('bovigo\vfs\vfsStream');

@trigger_error('Using the "org\bovigo\vfs\vfsStream" class is deprecated since version 2 and will be removed in version 3, use "bovigo\vfs\vfsStream" instead.', E_USER_DEPRECATED);

if (\false) {
/** @deprecated since 2, use "bovigo\vfs\vfsStream" instead */
class vfsStream extends Base
{
}
}
18 changes: 18 additions & 0 deletions org/bovigo/vfs/vfsStreamAbstractContent.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<?php

declare(strict_types=1);

namespace org\bovigo\vfs;

use bovigo\vfs\vfsStreamAbstractContent as Base;

class_exists('bovigo\vfs\vfsStreamAbstractContent');

@trigger_error('Using the "org\bovigo\vfs\vfsStreamAbstractContent" class is deprecated since version 2 and will be removed in version 3, use "bovigo\vfs\vfsStreamAbstractContent" instead.', E_USER_DEPRECATED);

if (\false) {
/** @deprecated since 2, use "bovigo\vfs\vfsStreamAbstractContent" instead */
abstract class vfsStreamAbstractContent extends Base
{
}
}
Loading

0 comments on commit 0cb695e

Please sign in to comment.