jobtest: add test for killing a subjob
ClosedPublic

Authored by dfaure on Mar 13 2019, 11:25 PM.

Details

Summary
  • it turns out that the whole job gets terminated
  • after changing FakeSession to delay reconnect like Session,

the unittest actually makes more sense (no more comment about signal not
received because emitted from the constructor)

  • call socketDisconnected like Session ends up doing

The main point was to debug a crash I was having in TransactionSequence
when killing subjobs in rollback(). The take away is that disconnecting
from slotResult is a horrible idea, it means mCurrentSubJob stays
dangling and later lostConnection() crashes. Disconnecting is currently
only done for non-running jobs, but too much code sharing brought me into
that bug :)

Diff Detail

Repository
R165 Akonadi
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
dfaure created this revision.Mar 13 2019, 11:25 PM
Restricted Application added a project: KDE PIM. · View Herald TranscriptMar 13 2019, 11:25 PM
dfaure requested review of this revision.Mar 13 2019, 11:25 PM
dvratil accepted this revision.Mar 21 2019, 3:47 PM
This revision is now accepted and ready to land.Mar 21 2019, 3:47 PM
This revision was automatically updated to reflect the committed changes.