Skip to content
This repository has been archived by the owner on Jan 30, 2020. It is now read-only.

Commit

Permalink
Merge branch 'cs/psr-2' of https://github.com/Maks3w/zf2
Browse files Browse the repository at this point in the history
  • Loading branch information
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions test/Adapter/MockupStream.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class MockupStream

public static $tests = array();

function stream_open($path, $mode, $options, &$opened_path)
public function stream_open($path, $mode, $options, &$opened_path)
{
$url = parse_url($path);
$this->test = $url["host"];
Expand All @@ -34,14 +34,14 @@ function stream_open($path, $mode, $options, &$opened_path)
return true;
}

function stream_read($count)
public function stream_read($count)
{
$ret = substr(self::$tests[$this->test], $this->position, $count);
$this->position += strlen($ret);
return $ret;
}

function stream_write($data)
public function stream_write($data)
{
$left = substr(self::$tests[$this->test], 0, $this->position);
$right = substr(self::$tests[$this->test], $this->position + strlen($data));
Expand All @@ -50,17 +50,17 @@ function stream_write($data)
return strlen($data);
}

function stream_tell()
public function stream_tell()
{
return $this->position;
}

function stream_eof()
public function stream_eof()
{
return $this->position >= strlen(self::$tests[$this->test]);
}

function stream_seek($offset, $whence)
public function stream_seek($offset, $whence)
{
switch ($whence) {
case SEEK_SET:
Expand Down

0 comments on commit a8bc04a

Please sign in to comment.