Add destroy to a task's allowed_operations

Signed-off-by: Jon Ludlam <jonathan.ludlam@citrix.com>
Move task_status_is_completed to TaskHelper

Signed-off-by: Jon Ludlam <jonathan.ludlam@citrix.com>
Don't destroy tasks that aren't complete

Signed-off-by: Jon Ludlam <jonathan.ludlam@citrix.com>