refactor expectation into exceptions