The first time I got into touch with data migration, I thought it was a tough thing. I have never done it before. How to start is a headache.
As a result, various data sources on the Internet finally summarized two key points: Black Box + white box. In this way, the test validity can be fully guaranteed.
Let's talk about the black box section.
In fact, there is not much to say about the Black Box. The main thing is to first understand which part of the content has been migrated, and then you will know how to proceed. For example, our project only migrates part of the message. My goal is clear, as long as all the scenarios after message migration are available and old data is normal, available, and available. In short, it should include the following six points.
1. Whether the old data can be normally displayed after migration, and will not be lost;
2. Can the old data be edited and updated after migration;
3. Whether the old data will be migrated again and migrated successfully after the kill process, shutdown, restart, and so on are destroyed during the migration;
4. Whether the old data that has not been downloaded can be successfully downloaded and displayed after being migrated to the new version;
5. Log On again after you exit to check whether the migration is successful;
6. Can the old data be migrated normally when the old data volume is large (a large amount of data needs to be directly inserted into the database for test data construction ).
Let me talk about the white box section.
The white box test is easier for me to do this. Directly copy the dB of the New and Old databases and perform comparative analysis to check the field differences between the two databases. Whether the various old fields correspond to the new dB. The specific situation needs to be analyzed according to different projects. I will not go into details here.
Practical Operation: A root Android phone is required to install a root explorer, using re to find the corresponding path, you can directly view the DB, export the dB, and so on (it is very convenient to move the file in the Android mobile phone, select a content to move, long press and select move, find the location to be placed and click here to complete the move-you need to press and open the file for Operation permissions ).
PS: if the database has created a large amount of data, you can reuse the database. Place the constructed old database to the dB of the old version. Open the old version and you will see a large amount of data.
Data migration practices