mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-07-18 23:25:04 +02:00
- Refactoring to reduce duplication - Clear user from stream context when "logging out" - Add test that switches user and checks for access
51 lines
987 B
PHP
51 lines
987 B
PHP
<?php
|
|
|
|
/**
|
|
* Test the basic Vfs::StreamWrapper
|
|
*
|
|
* @link http://www.egroupware.org
|
|
* @author Nathan Gray
|
|
* @copyright (c) 2020 Nathan Gray
|
|
* @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License
|
|
*/
|
|
|
|
namespace EGroupware\Api\Vfs;
|
|
|
|
require_once __DIR__ . '/StreamWrapperBase.php';
|
|
|
|
use EGroupware\Api;
|
|
use EGroupware\Api\LoggedInTest as LoggedInTest;
|
|
use EGroupware\Api\Vfs;
|
|
use EGroupware\Stylite\Vfs\Versioning;
|
|
|
|
|
|
class StreamWrapperTest extends StreamWrapperBase
|
|
{
|
|
protected function setUp() : void
|
|
{
|
|
parent::setUp();
|
|
}
|
|
|
|
protected function tearDown() : void
|
|
{
|
|
// Do local stuff first, parent will remove stuff
|
|
|
|
parent::tearDown();
|
|
}
|
|
|
|
public function testSimpleReadWrite(): string
|
|
{
|
|
$this->files[] = $this->test_file = $this->getFilename();
|
|
|
|
return parent::testSimpleReadWrite();
|
|
}
|
|
|
|
|
|
public function testNoReadAccess(): void
|
|
{
|
|
$this->files[] = $this->test_file = $this->getFilename();
|
|
|
|
parent::testNoReadAccess();
|
|
}
|
|
|
|
} |