diff options
author | 2019-05-28 10:19:21 +0200 | |
---|---|---|
committer | 2019-06-03 10:01:26 +0200 | |
commit | adf44f2a5eeb056c5fece0454d3e09d08df160fe (patch) | |
tree | aee220cedfccc15f59bccfae1ca7ec6b4a904809 /test/util.py | |
parent | 6dfe3074e92b3188c9fa72303f4135442cc0d5dd (diff) |
[TEST] - Initialize to use of YDK in sweetcomb test
- remove netopeer client
- use YDK
- check result, assert when error
Change-Id: Icb29dd5a35e8f7dbbeff2e44ec088b890f93b5ef
Signed-off-by: Andrej Kozemcak <andrej.kozemcak@pantheon.tech>
Diffstat (limited to 'test/util.py')
-rw-r--r-- | test/util.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/test/util.py b/test/util.py index c31439d..576bc43 100644 --- a/test/util.py +++ b/test/util.py @@ -1,5 +1,6 @@ # # Copyright (c) 2019 PANTHEON.tech. +# Copyright (c) 2019 Cisco and/or its affiliates. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -18,13 +19,16 @@ import subprocess import os import time + def ping(ip): subprocess.run("ping -c 4 " + ip, shell=True) + def import_yang_modules(): print("Import YANG models to sysrepo.") - directory = '/root/src/sweetcomb/' + #directory = '/root/src/sweetcomb/' + directory = './' os.chdir(directory) subprocess.run(["make", "uninstall-models"]) subprocess.run(["make", "install-models"]) @@ -38,4 +42,4 @@ def import_yang_modules(): "--datastore=running", "--format=xml", "--leve=0", "ietf-interfaces"]) os.chdir(directory) - time.sleep(2)
\ No newline at end of file + time.sleep(2) |