pulled in changes from https://code.google.com/p/opendatakit/issues/detail?id=814 by chris
add test for cleaner error message