tests: Add synctest

synctest is a simple test wrapper for the synctest test
suite. It's an example of suite compilation and execution.
Signed-off-by: NLucas Meneghel Rodrigues <lmr@redhat.com>
上级 ffba5147
import os
from avocado import test
from avocado.utils import archive
from avocado.utils import build
from avocado.utils import process
class synctest(test.Test):
"""
Execute the synctest test suite.
"""
def setup(self, tarball='synctest.tar.bz2'):
tarball_path = self.get_deps_path(tarball)
tarball = archive.extract(tarball_path, self.srcdir)
self.srcdir = os.path.join(self.srcdir, 'synctest')
build.make(self.srcdir)
def action(self, length=100, loop=10):
os.chdir(self.srcdir)
cmd = './synctest %s %s' % (length, loop)
process.system(cmd)
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册