java - Force IOException to happen in Android while reading a file without mocking -


how make ioexception happen testing? in particular, app reading file on external storage. possible, example, instruct os close file handle specific app process next read() throws ioexception?

on real device, can done physically, removing external storage media.


Comments

Popular posts from this blog

java - Date formats difference between yyyy-MM-dd'T'HH:mm:ss and yyyy-MM-dd'T'HH:mm:ssXXX -

c# - Get rid of xmlns attribute when adding node to existing xml -