aboutsummaryrefslogtreecommitdiff
path: root/tests/test_comp_life.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_comp_life.py')
-rw-r--r--tests/test_comp_life.py23
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/test_comp_life.py b/tests/test_comp_life.py
new file mode 100644
index 0000000..ad78e52
--- /dev/null
+++ b/tests/test_comp_life.py
@@ -0,0 +1,23 @@
+from avp.command import Command
+from pytestqt import qtbot
+from pytest import fixture
+from . import imageDataSum
+
+
+@fixture
+def coreWithLifeComp(qtbot):
+ """Fixture providing a Command object with Waveform component added"""
+ command = Command()
+ command.settings.setValue("outputHeight", 1080)
+ command.settings.setValue("outputWidth", 1920)
+ command.core.insertComponent(
+ 0, command.core.moduleIndexFor("Conway's Game of Life"), command
+ )
+ yield command.core
+
+
+def test_comp_life_previewRender(coreWithLifeComp):
+ comp = coreWithLifeComp.selectedComponents[0]
+ comp.page.lineEdit_color.setText("111,111,111")
+ image = comp.previewRender()
+ assert imageDataSum(image) == 339785512