Commit 21713f43 authored by Zhang, Hua's avatar Zhang, Hua Committed by olivier R-D

bugfix: test should call default python version

parent a154b429
......@@ -941,25 +941,25 @@ class TestCmdLines(unittest.TestCase):
self.srv.start()
def test_uals(self):
s = subprocess.check_output(["python3", "tools/uals", "--url", self.srv_url])
s = subprocess.check_output(["python", "tools/uals", "--url", self.srv_url])
self.assertIn(b"i=85", s)
self.assertNotIn(b"i=89", s)
self.assertNotIn(b"1.999", s)
s = subprocess.check_output(["python3", "tools/uals", "--url", self.srv_url, "-d", "3"])
s = subprocess.check_output(["python", "tools/uals", "--url", self.srv_url, "-d", "3"])
self.assertIn(b"1.999", s)
def test_uaread(self):
s = subprocess.check_output(["python3", "tools/uaread", "--url", self.srv_url, "--path", "0:Objects,4:directory,4:variable"])
s = subprocess.check_output(["python", "tools/uaread", "--url", self.srv_url, "--path", "0:Objects,4:directory,4:variable"])
self.assertIn(b"1.999", s)
def test_uawrite(self):
s = subprocess.check_output(["python3", "tools/uawrite", "--url", self.srv_url, "--path", "0:Objects,4:directory,4:variable2", "1.789"])
s = subprocess.check_output(["python3", "tools/uaread", "--url", self.srv_url, "--path", "0:Objects,4:directory,4:variable2"])
s = subprocess.check_output(["python", "tools/uawrite", "--url", self.srv_url, "--path", "0:Objects,4:directory,4:variable2", "1.789"])
s = subprocess.check_output(["python", "tools/uaread", "--url", self.srv_url, "--path", "0:Objects,4:directory,4:variable2"])
self.assertIn(b"1.789", s)
self.assertNotIn(b"1.999", s)
def test_uadiscover(self):
s = subprocess.check_output(["python3", "tools/uadiscover", "--url", self.srv_url])
s = subprocess.check_output(["python", "tools/uadiscover", "--url", self.srv_url])
self.assertIn(b"opc.tcp://localhost", s)
self.assertIn(b"FreeOpcUa", s)
self.assertIn(b"urn:freeopcua:python:server", s)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment