import sys
from sequana.gui import messages
from PyQt5 import QtWidgets as QW

app = QW.QApplication(sys.argv)

def test_warning():
    w = messages.WarningMessage("test")


def test_critical():
    w = messages.CriticalMessage("test", details="test")





from sequana.gui import messages


def test_warning(qtbot):
    w = messages.WarningMessage("test")


def test_critical(qtbot):
    w = messages.CriticalMessage("test", details="test")





Fix test that caused a pytest hang
Fix test that caused a pytest hang

- import sys
  from sequana.gui import messages
- from PyQt5 import QtWidgets as QW
  
- app = QW.QApplication(sys.argv)
  
- def test_warning():
+ def test_warning(qtbot):
      w = messages.WarningMessage("test")
  
  
- def test_critical():
+ def test_critical(qtbot):
      w = messages.CriticalMessage("test", details="test")
  
  
  
  
  
Fix test that caused a pytest hang
## Code Before:
import sys
from sequana.gui import messages
from PyQt5 import QtWidgets as QW

app = QW.QApplication(sys.argv)

def test_warning():
    w = messages.WarningMessage("test")


def test_critical():
    w = messages.CriticalMessage("test", details="test")





## Instruction:
Fix test that caused a pytest hang
## Code After:
from sequana.gui import messages


def test_warning(qtbot):
    w = messages.WarningMessage("test")


def test_critical(qtbot):
    w = messages.CriticalMessage("test", details="test")




