general assertion and expectation functions