2008/4/23 Piotr Czachur <[EMAIL PROTECTED]>:
> Hello!
>
> I use PHPUnit for unit testing of my application (but this issue is
> independent of PHPUnit). Tests are run from command line so it's not
> way (that I can imagine) to simulate file upload, because app code
> uses is_uploaded_file() to
I think - you can write wrapper for file
class file{
public function is_uploaded(){
return SingletonContextObject::isForTestingFileIsUpload() ||
is_uploaded_file($this->filepath);
}
}
Piotr Czachur пишет:
Hello!
I use PHPUnit for unit testing of my application (but this issue is
independe