test_process_manager.py 386 B

12345678910111213141516171819202122
  1. from facefusion.process_manager import end, is_pending, is_processing, is_stopping, set_process_state, start, stop
  2. def test_start() -> None:
  3. set_process_state('pending')
  4. start()
  5. assert is_processing()
  6. def test_stop() -> None:
  7. set_process_state('processing')
  8. stop()
  9. assert is_stopping()
  10. def test_end() -> None:
  11. set_process_state('processing')
  12. end()
  13. assert is_pending()