async def test_receive_proposal(self):
    connection_record = async_mock.MagicMock(connection_id=CONN_ID)
    proposal = V20PresProposal()
    with async_mock.patch.object(V20PresExRecord, 'save', autospec=True) as save_ex:
        px_rec = (await self.manager.receive_pres_proposal(proposal, connection_record))
        save_ex.assert_called_once()
        assert (px_rec.state == V20PresExRecord.STATE_PROPOSAL_RECEIVED)
async def test_receive_proposal(self):
    connection_record = async_mock.MagicMock(connection_id=CONN_ID)
    proposal = V20PresProposal()
    with async_mock.patch.object(V20PresExRecord, 'save', autospec=True) as save_ex:
        px_rec = (await self.manager.receive_pres_proposal(proposal, connection_record))
        save_ex.assert_called_once()
        assert (px_rec.state == V20PresExRecord.STATE_PROPOSAL_RECEIVED)