diff options
author | Pavel Kotucek <pavel.kotucek@pantheon.tech> | 2019-05-22 15:23:41 +0200 |
---|---|---|
committer | Hongjun Ni <hongjun.ni@intel.com> | 2019-05-23 04:13:53 +0000 |
commit | 931b7d52a023ea73e596d90c6e9e938de903100b (patch) | |
tree | 2a65632d12bb35f1892e76b8ccd804ab84da21b8 /test/netopeer_controler.py | |
parent | ce1a0daa15be4c3b7a3df64ea57ad231664e700f (diff) |
Docker test improvementsvom
Small changes to enable kept running vpp and sysrepo instances after
test execution.
Fixed typos (file name and and method in py file).
Change-Id: I32e56464e61bf1548984ea9845a8d08cf6a3917b
Signed-off-by: Pavel Kotucek <pavel.kotucek@pantheon.tech>
Diffstat (limited to 'test/netopeer_controler.py')
-rw-r--r-- | test/netopeer_controler.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/test/netopeer_controler.py b/test/netopeer_controler.py index 74c7dc6..e95cbb4 100644 --- a/test/netopeer_controler.py +++ b/test/netopeer_controler.py @@ -42,6 +42,7 @@ class Netopeer_controler: def spawn(self): self.child = pexpect.spawn(self.name) self.child.logfile = open('/var/log/Netopeer_controler.log', 'wb') + self.child.setwinsize(1,1024) self.pid = self.child.pid self.child.expect(">") self.child.sendline("connect\r") @@ -58,7 +59,7 @@ class Netopeer_controler: def get(self, msg): self.child.sendline("get --filter-xpath {}\r".format(msg)) self.child.expect("> ") - print(self.child.before.decode('ascii')) + return self.child.before.decode('ascii') def edit_config(self, msg): f = open("/tmp/tmp_example.xml", "w") @@ -67,4 +68,4 @@ class Netopeer_controler: self.child.sendline("edit-config --target running --config=/tmp/tmp_example.xml\r") self.child.expect("> ") - print(self.child.before.decode('ascii')) + return self.child.before.decode('ascii') |