Http://stackoverflow.com/questions/2524326/how-to-test-an-iphone-application-update
I already have an iPhone application (version 1.0) available in the App Store and am ready to submit a newer version (Version 1.1 ). how do I test the new upgrade to make sure that the current SQLite database and property list files on the earlier version do not get deleted/overwritten etc? The new version assumes the old data in both the SQLite database and property lists remain.
Or better yet, is there a resource I can use to walk me through what to watch for when developing an application update?
The way we tackled this when we wanted to test our Database Upgrade Code was to use ad hoc distribution.
We had our testers download the 1.0 app from iTunes and install it on their test devices.
Then we built an ad hoc distribution of the APP using a configuration based on the release config, and made sure that it had the same bundle identifier. as long as the bundle identifier is the same, the new app shoshould overwrite the previous version.
We asked our testers to install the ad hoc build as they normally wo'd, by dragging it into iTunes and then syncing the device to simulate upgrading.
As far as I know, this is identical to the user downloading and installing an upgrade via the App Store on the device itself.
As you 'd expect CT, the clients folder shocould be left intact, leaving your database in place, and your app shocould be able to run it's upgrade code to modify the database in the way you need.
Hope this helps
Test like so:
- Delete app from device.
- Install V1.0 app (or. IPA file) into iTunes
- Sync to device, iTunes will install the app
- Launch app on device, create and save data, etc.
- Quit app on Device
- Install V1.1 app (or. IPA file) into iTunes; iTunes will ask to confirm replacing older version of the app.
- Sync to device, iTunes will update the app
- Launch app on Device
- Test using existing data with new version of the app.