Improved ActivityInstanceTest