Added object linking integration test

This commit is contained in:
Emmanuel Durand
2017-04-12 20:07:36 -04:00
parent b3475915d1
commit 1cfdfd0a79
+33
View File
@@ -0,0 +1,33 @@
import splash
from time import sleep
description = "Test linking / unlinking various objects"
def link_window_image():
print("---> Linking window and image")
splash.set_global("sendAllScenes", ["unlink", "cam1", "win1"])
splash.set_global("sendAllScenes", ["link", "image", "win1"])
sleep(1.0)
splash.set_global("sendAllScenes", ["unlink", "image", "win1"])
sleep(1.0)
splash.set_global("sendAllScenes", ["link", "image", "win1"])
sleep(1.0)
splash.set_global("sendAllScenes", ["unlink", "image", "win1"])
sleep(1.0)
splash.set_global("sendAllScenes", ["link", "cam1", "win1"])
sleep(1.0)
def link_object_image():
print("---> Linking object and image")
splash.set_global("sendAllScenes", ["unlink", "image", "object"])
sleep(1.0)
splash.set_global("sendAllScenes", ["link", "image", "object"])
sleep(1.0)
splash.set_global("sendAllScenes", ["unlink", "image", "object"])
sleep(1.0)
splash.set_global("sendAllScenes", ["link", "image", "object"])
sleep(1.0)
def run():
link_window_image()
link_object_image()