Skip to content

Commit

Permalink
Merge pull request zendframework#2637 from gabriel403/hotfix/posix_ge…
Browse files Browse the repository at this point in the history
…tuid

posix_getuid in test fixes
  • Loading branch information
Freeaqingme committed Oct 1, 2012
2 parents c42f0bd + 19ad86d commit 18b11f9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/ZendTest/Mail/Storage/MboxFolderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,8 @@ public function testNotReadableFolder()
if (!$check) {
if (function_exists('posix_getuid') && posix_getuid() === 0) {
$this->markTestSkipped('seems like you are root and we therefore cannot test the error handling');
} elseif (!function_exists('posix_getuid')) {
$this->markTestSkipped('Can\t test if you\'re root and we therefore cannot test the error handling');
}
$this->fail('no exception while loading invalid dir with subfolder not readable');
}
Expand Down
2 changes: 2 additions & 0 deletions tests/ZendTest/Mail/Storage/MboxTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -263,6 +263,8 @@ public function testSleepWakeRemoved()
if (!$check) {
if (function_exists('posix_getuid') && posix_getuid() === 0) {
$this->markTestSkipped('seems like you are root and we therefore cannot test the error handling');
} elseif (!function_exists('posix_getuid')) {
$this->markTestSkipped('Can\t test if you\'re root and we therefore cannot test the error handling');
}
$this->fail('no exception while waking with non readable file');
}
Expand Down

0 comments on commit 18b11f9

Please sign in to comment.