ushahidi/Lamu — pull request #60 by rjmackay (2013-06-04 02:27:09+00:00)
Title: Ushahidi 2.x to 3.x Migration Script

This is the first cut at a 2.x to 3.x migration script. You can import from DB or API.

To view task docs:
```./minion --task=ushahidi:import2x --help```

To import from API
```./minion --task=ushahidi:import2x --source=api --url=http://zombiereports.com```

To import from DB
```./minion --task=ushahidi:import2x --source=db --database=ushahidi_zombie --username=ushahidi --password=ushahidi```

**Things not covered:**
* Can't get unapproved reports via API - this is a 2.x issue
* Can't get incident person data from the API - 2.x issue
* Can't get hidden categories from API - 2.x issue
* We don't have anywhere to store category color, icon or visibility yet
* Not importing users - this code would be best built with the users API #17
* Not importing custom fields or data yet - I'd rather just spin this out to another task to build later.
* Can't import photos - no way to handle media yet #53
* Not importing incident person data from DB - need to figure out where to store it. Related #54

**Testing**
I'm struggling to figure out how to test this. I can write some behat magic to run the migration script but it would rely on external factors: 1. external 2.x db or 2. external 2.x api
Which would mean it failing anytime those weren't set up. Any ideas?