Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to simulate an out of disk space condition on iOS devices?

I would like to test out some code I have in place to manage conditions where there's not enough free disk space to complete the operations.

However, I'm having trouble achieving such situation. I have tried to sync stuff from iTunes to fill up the devices, but either I get too much disk space free or the content will exceed the device capacity and iTunes will not allow the sync.

I'm sure there must be an easier and better strategy to test this situation on the device, but I can't figure it out. I would appreciate and tips or experiences you can share about this.

like image 526
flainez Avatar asked Nov 22 '12 18:11

flainez


Video Answer


1 Answers

Fill up the device until it's nearly at the limit in iTunes, then set a loop to copy a largish file into your Documents directory. Each time you copy it, give it a unique name (use UUID). Activate the loop to run a number of times with a control in your interface, or with a timer.

like image 170
nevan king Avatar answered Sep 29 '22 18:09

nevan king