Add test to verify work state during error.