Skip to content

Commit 1367258

Browse files
Add selenium draft tests.
Signed-off-by: Andrei Stepanov <[email protected]>
1 parent d2c21ac commit 1367258

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+10415
-0
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,3 +62,5 @@ tools/github/*cache
6262
tmp
6363
.*.swp
6464
RELEASE-VERSION
65+
docs/build
66+
docs/source/api

README.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ This is tests provider from SPICE QE
3434

3535
http://virt-test.readthedocs.org/en/latest/basic/TestProviders.html
3636

37+
Test files can be at any directory. Avocado-VT will be able to find it.
38+
3739
**********
3840
virtio-win
3941
**********

TODO

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
* Import selftests from avocado.
22
* Add https://coveralls.io and status to README.rst
33

4+
* Add tests to TCMS:
5+
rv_vmshutdown.shutdown_cmdline
6+
rv_vmshutdown.shutdown_qemu
7+
48

59

610
Drag-and-drop automation thoughts:

docs/source/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ Library & tests:
1313
:maxdepth: 1
1414
:numbered:
1515

16+
quickstart
1617
api/*
1718

1819
README

docs/source/quickstart.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
Quick start.
2+
============
3+
4+
* Put here documentation.
5+
* Check with: http://rst.ninjs.org/

dotme.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
PYTHONPATH="$PYTHONPATH:$HOME/git/avocado-vt"
2+
PYTHONPATH="$PYTHONPATH:$HOME/git/avocado"
3+
export PYTHONPATH

spice/cfg/tests-variants.cfg

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -566,3 +566,11 @@ variants:
566566
- 333685:
567567
rv_parameters_from = file
568568
include join.cfg
569+
570+
- ovirt:
571+
572+
variants:
573+
574+
- user_portal_connect
575+
type = user_portal_connect
576+
include join.cfg

spice/deps/selenium.ini

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
[selenium]
2+
title = Selenium Standalone Server
3+
url = http://selenium-release.storage.googleapis.com/3.0-beta2/selenium-server-standalone-3.0.0-beta2.jar
4+
destination = selenium-server-standalone.jar

spice/lib/stest.py

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -215,3 +215,23 @@ class GuestTest(OneVMTest):
215215
"""
216216
def __init__(self, test, parameters, env):
217217
super(GuestTest, self).__init__(test, parameters, env)
218+
219+
220+
def download_asset(asset_name, ini_dir=None, section=None, ddir=None):
221+
provider_dirs = asset.get_test_provider_subdirs(backend="spice")
222+
if ini_dir:
223+
provider_dirs.insert(0, ini_dir)
224+
for d in provider_dirs:
225+
ini_file = os.path.join(d, "%s.ini" % asset_name)
226+
if os.path.isfile(ini_file):
227+
asset_dir=d
228+
break
229+
assert os.path.isfile(ini_file), "Cannot find %.ini file." % asset_name
230+
asset_info = asset.get_asset_info(asset_name, ini_dir=asset_dir,
231+
section=asset_section)
232+
logger.info("Asset info: %s" % asset_info)
233+
if ddir:
234+
dst_file=os.path.basename(asset_info['destination'])
235+
asset_info['destination'] = os.path.join(ddir, dst_file)
236+
asset.download_file(asset_info)
237+
logger.info("Use: %s" % asset_info['destination'])

spice/ovirt/README.rst

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
Selenium tests were inspired by rhevm-raut. Raut is written by Pavel Novotny
2+
3+
4+
* https://code.engineering.redhat.com/gerrit/#/admin/projects/rhevm-raut
5+
* https://mojo.redhat.com/docs/DOC-1084114
6+
* http://art-build-srv.qa.lab.tlv.redhat.com/pytest/rhel/7.2/Packages/
7+
* http://git.app.eng.bos.redhat.com/git/rhevm-qe-utils.git
8+
* http://art-build-srv.qa.lab.tlv.redhat.com/help/
9+
* https://code.engineering.redhat.com/gerrit/gitweb?p=rhevm-qe-automation/rhevm-art.git;a=tree
10+

0 commit comments

Comments
 (0)