Skip to content

Unit test for DriveHandler and CleanerSession

I started working on a unit test which would catch a regression related to https://gitlab.cern.ch/cta/operations/-/issues/708

According to my plan, the test should:

  1. Create a process manager
  2. Add a drive handler to the process manager
  3. Create a tape session reporter
  4. Report session statuses via reporter like in normal workflow
  5. At some point send the Fatal status
  6. Run process manager: it starts a loop for receiving messages and lets the drive handler process them
  7. Drive handler reacts to Fatal and terminates the session
  8. Drive handler starts a cleaner session
  9. Cleaner session finds VID and runs as it should
  10. Send shutdown signal, kill gracefully the handler subprocesses and stop running the process manager