summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAntonio Terceiro <antonio.terceiro@linaro.org>2013-11-21 21:09:42 (GMT)
committerAntonio Terceiro <antonio.terceiro@linaro.org>2013-11-21 21:09:42 (GMT)
commit1e1d6bd50bf1817e696afd6bd885390599de618f (patch)
treecf219d5f6b0230deb48444aafde5d9f909acac4f
parent7f51b32eae94f2fd573b1f782c104754bd5f0638 (diff)
parent86367cf8b83876bbe5fbe24ab21372577817196d (diff)
downloadlava-dispatcher-merge-linaro-dashboard-bundle.tar.gz
lava-dispatcher-merge-linaro-dashboard-bundle.tar.xz
Merge branch 'master' into merge-linaro-dashboard-bundlemerge-linaro-dashboard-bundle
-rw-r--r--MANIFEST.in3
-rw-r--r--lava_dispatcher/actions/lava_test_shell.py46
-rw-r--r--lava_dispatcher/client/lmc_utils.py1
-rw-r--r--lava_dispatcher/config.py2
-rw-r--r--lava_dispatcher/default-config/lava-dispatcher/device-types/amarillo.conf28
-rw-r--r--lava_dispatcher/default-config/lava-dispatcher/device-types/imx6q-wandboard.conf21
-rw-r--r--lava_dispatcher/default-config/lava-dispatcher/device-types/xi3.conf2
-rw-r--r--lava_dispatcher/device/bootloader.py2
-rw-r--r--lava_dispatcher/device/target.py13
-rw-r--r--lava_dispatcher/lava_test_shell/README (renamed from lava_test_shell/README)0
-rwxr-xr-xlava_dispatcher/lava_test_shell/distro/android/lava-test-runner (renamed from lava_test_shell/distro/android/lava-test-runner)0
-rw-r--r--lava_dispatcher/lava_test_shell/distro/fedora/lava-install-packages (renamed from lava_test_shell/distro/fedora/lava-install-packages)0
-rw-r--r--lava_dispatcher/lava_test_shell/distro/fedora/lava-installed-packages (renamed from lava_test_shell/distro/fedora/lava-installed-packages)0
-rw-r--r--lava_dispatcher/lava_test_shell/distro/fedora/lava-os-build (renamed from lava_test_shell/distro/fedora/lava-os-build)0
-rw-r--r--lava_dispatcher/lava_test_shell/distro/ubuntu/lava-install-packages (renamed from lava_test_shell/distro/ubuntu/lava-install-packages)0
-rw-r--r--lava_dispatcher/lava_test_shell/distro/ubuntu/lava-installed-packages (renamed from lava_test_shell/distro/ubuntu/lava-installed-packages)0
-rw-r--r--lava_dispatcher/lava_test_shell/distro/ubuntu/lava-os-build (renamed from lava_test_shell/distro/ubuntu/lava-os-build)0
-rw-r--r--lava_dispatcher/lava_test_shell/lava-installed-packages (renamed from lava_test_shell/lava-installed-packages)0
-rw-r--r--lava_dispatcher/lava_test_shell/lava-os-build (renamed from lava_test_shell/lava-os-build)0
-rw-r--r--lava_dispatcher/lava_test_shell/lava-test-case (renamed from lava_test_shell/lava-test-case)0
-rw-r--r--lava_dispatcher/lava_test_shell/lava-test-case-attach (renamed from lava_test_shell/lava-test-case-attach)0
-rw-r--r--lava_dispatcher/lava_test_shell/lava-test-run-attach (renamed from lava_test_shell/lava-test-run-attach)0
-rwxr-xr-xlava_dispatcher/lava_test_shell/lava-test-runner (renamed from lava_test_shell/lava-test-runner)14
-rwxr-xr-xlava_dispatcher/lava_test_shell/lava-test-shell (renamed from lava_test_shell/lava-test-shell)0
-rw-r--r--lava_dispatcher/lava_test_shell/lmp/lava-lmp-audio-jack (renamed from lava_test_shell/lmp/lava-lmp-audio-jack)0
-rw-r--r--lava_dispatcher/lava_test_shell/lmp/lava-lmp-eth (renamed from lava_test_shell/lmp/lava-lmp-eth)0
-rw-r--r--lava_dispatcher/lava_test_shell/lmp/lava-lmp-hdmi (renamed from lava_test_shell/lmp/lava-lmp-hdmi)0
-rw-r--r--lava_dispatcher/lava_test_shell/lmp/lava-lmp-lsgpio (renamed from lava_test_shell/lmp/lava-lmp-lsgpio)0
-rw-r--r--lava_dispatcher/lava_test_shell/lmp/lava-lmp-sata (renamed from lava_test_shell/lmp/lava-lmp-sata)0
-rw-r--r--lava_dispatcher/lava_test_shell/lmp/lava-lmp-usb (renamed from lava_test_shell/lmp/lava-lmp-usb)0
-rw-r--r--lava_dispatcher/lava_test_shell/lmp/lava-lmp.lib (renamed from lava_test_shell/lmp/lava-lmp.lib)0
-rw-r--r--lava_dispatcher/lava_test_shell/multi_node/lava-group (renamed from lava_test_shell/multi_node/lava-group)0
-rw-r--r--lava_dispatcher/lava_test_shell/multi_node/lava-multi-node.lib (renamed from lava_test_shell/multi_node/lava-multi-node.lib)0
-rw-r--r--lava_dispatcher/lava_test_shell/multi_node/lava-network (renamed from lava_test_shell/multi_node/lava-network)0
-rw-r--r--lava_dispatcher/lava_test_shell/multi_node/lava-role (renamed from lava_test_shell/multi_node/lava-role)0
-rw-r--r--lava_dispatcher/lava_test_shell/multi_node/lava-self (renamed from lava_test_shell/multi_node/lava-self)0
-rw-r--r--lava_dispatcher/lava_test_shell/multi_node/lava-send (renamed from lava_test_shell/multi_node/lava-send)0
-rw-r--r--lava_dispatcher/lava_test_shell/multi_node/lava-sync (renamed from lava_test_shell/multi_node/lava-sync)0
-rw-r--r--lava_dispatcher/lava_test_shell/multi_node/lava-wait (renamed from lava_test_shell/multi_node/lava-wait)0
-rw-r--r--lava_dispatcher/lava_test_shell/multi_node/lava-wait-all (renamed from lava_test_shell/multi_node/lava-wait-all)0
-rw-r--r--lava_dispatcher/utils.py2
-rwxr-xr-xsetup.py30
42 files changed, 109 insertions, 55 deletions
diff --git a/MANIFEST.in b/MANIFEST.in
index 2b5b500..b656271 100644
--- a/MANIFEST.in
+++ b/MANIFEST.in
@@ -8,9 +8,6 @@ include lava_dispatcher/default-config/lava-dispatcher/README
include lava_dispatcher/tests/test-config/bin/*
include lava_dispatcher/tests/test-config/devices/*
include lava_dispatcher/tests/test-config/*
-include lava_test_shell/distro/fedora/*
-include lava_test_shell/distro/ubuntu/*
-include lava_test_shell/distro/android/*
include requirements.txt
include doc/*
include man/*
diff --git a/lava_dispatcher/actions/lava_test_shell.py b/lava_dispatcher/actions/lava_test_shell.py
index 22d2c30..2ad10b3 100644
--- a/lava_dispatcher/actions/lava_test_shell.py
+++ b/lava_dispatcher/actions/lava_test_shell.py
@@ -134,9 +134,9 @@ from lava_dispatcher.device.target import Target
from lava_dispatcher.downloader import download_image
from lava_dispatcher.errors import GeneralError
-LAVA_TEST_DIR = '%s/../../lava_test_shell' % os.path.dirname(__file__)
-LAVA_MULTI_NODE_TEST_DIR = '%s/../../lava_test_shell/multi_node' % os.path.dirname(__file__)
-LAVA_LMP_TEST_DIR = '%s/../../lava_test_shell/lmp' % os.path.dirname(__file__)
+LAVA_TEST_DIR = '%s/../lava_test_shell' % os.path.dirname(__file__)
+LAVA_MULTI_NODE_TEST_DIR = '%s/../lava_test_shell/multi_node' % os.path.dirname(__file__)
+LAVA_LMP_TEST_DIR = '%s/../lava_test_shell/lmp' % os.path.dirname(__file__)
LAVA_GROUP_FILE = 'lava-group'
LAVA_ROLE_FILE = 'lava-role'
@@ -344,10 +344,9 @@ class TestDefinitionLoader(object):
testdef_repo)
else:
if 'parameters' in testdef_repo:
- metadata = {}
# get the parameters for test.
- metadata['test_params'] = str(testdef_repo['parameters'])
- self.context.test_data.add_metadata(metadata)
+ logging.debug('Get test parameters : %s' % testdef_repo['parameters'])
+ info['test_params'] = str(testdef_repo['parameters'])
test = testdef_repo.get('testdef', 'lavatest.yaml')
with open(os.path.join(repo, test), 'r') as f:
@@ -357,6 +356,10 @@ class TestDefinitionLoader(object):
if 'test-case-deps' in testdef:
self._get_dependent_test_cases(testdef)
+ # for test paramters
+ if 'params' in testdef:
+ info['default_params'] = ','.join(testdef.get('params'))
+
idx = len(self.testdefs)
self._append_testdef(
RepoTestDefinition(self.context, idx, testdef, repo, info))
@@ -465,8 +468,8 @@ class URLTestDefinition(object):
fout.write('######\n')
# inject the parameters that was set in json
fout.write('###test parameters from json###\n')
- if 'test_params' in self.context.test_data.metadata:
- _test_params_temp = eval(self.context.test_data.metadata['test_params'])
+ if 'test_params' in self._sw_sources[0]:
+ _test_params_temp = eval(self._sw_sources[0]['test_params'])
for param_name, param_value in _test_params_temp.items():
fout.write('%s=%s\n' % (param_name, param_value))
fout.write('######\n')
@@ -551,13 +554,6 @@ class RepoTestDefinition(URLTestDefinition):
testdef_metadata.update(_get_testdef_info(testdef))
testdef_metadata.update({'version': info['branch_revision']})
- # for test paramters
- metadata = {}
-
- if testdef.get('params'):
- metadata['default_params'] = ','.join(testdef.get('params'))
- context.test_data.add_metadata(metadata)
-
URLTestDefinition.__init__(self, context, idx, testdef,
testdef_metadata)
self.repo = repo
@@ -621,7 +617,10 @@ class cmd_lava_test_shell(BaseAction):
runner._connection.sendline(
"export http_proxy=%s" % self.context.config.lava_proxy, delay)
runner._connection.sendline(
- "%s/bin/lava-test-runner" % target.deployment_data['lava_test_dir'], delay)
+ "%s/bin/lava-test-runner %s" % (
+ target.lava_test_dir,
+ target.lava_test_dir),
+ delay)
start = time.time()
if timeout == -1:
timeout = runner._connection.timeout
@@ -728,7 +727,8 @@ class cmd_lava_test_shell(BaseAction):
elif foutname == LAVA_SELF_FILE:
fout.write("LAVA_HOSTNAME='%s'\n" % self.context.test_data.metadata['target.hostname'])
else:
- fout.write("LAVA_TEST_BIN='%s/bin'\n" % target.deployment_data['lava_test_dir'])
+ fout.write("LAVA_TEST_BIN='%s/bin'\n" %
+ target.lava_test_dir)
fout.write("LAVA_MULTI_NODE_CACHE='%s'\n" % LAVA_MULTI_NODE_CACHE_FILE)
logging_level = self.context.test_data.metadata.get(
'logging_level', None)
@@ -749,7 +749,8 @@ class cmd_lava_test_shell(BaseAction):
with open('%s/bin/%s' % (mntdir, foutname), 'w') as fout:
fout.write("#!%s\n\n" % shell)
# Target-specific scripts (add ENV to the generic ones)
- fout.write("LAVA_TEST_BIN='%s/bin'\n" % target.deployment_data['lava_test_dir'])
+ fout.write("LAVA_TEST_BIN='%s/bin'\n" %
+ target.lava_test_dir)
fout.write("LAVA_LMP_CACHE='%s'\n" % LAVA_LMP_CACHE_FILE)
if self.context.test_data.metadata['logging_level'] == 'DEBUG':
fout.write("LAVA_LMP_DEBUG='yes'\n")
@@ -762,12 +763,10 @@ class cmd_lava_test_shell(BaseAction):
utils.ensure_directory_empty('%s/results' % mntdir)
def _configure_target(self, target, testdef_urls, testdef_repos):
- ldir = target.deployment_data['lava_test_dir']
-
results_part = target.deployment_data['lava_test_results_part_attr']
results_part = getattr(target.config, results_part)
- with target.file_system(results_part, 'lava') as d:
+ with target.file_system(results_part, target.lava_test_dir) as d:
self._mk_runner_dirs(d)
self._copy_runner(d, target)
if 'target_group' in self.context.test_data.metadata:
@@ -791,7 +790,8 @@ class cmd_lava_test_shell(BaseAction):
# mounts under /, so we have hdir for where it is on the
# host and tdir for how the target will see the path
hdir = '%s/tests/%s' % (d, testdef.test_run_id)
- tdir = '%s/tests/%s' % (ldir, testdef.test_run_id)
+ tdir = '%s/tests/%s' % (target.lava_test_dir,
+ testdef.test_run_id)
testdef.copy_test(hdir, tdir)
tdirs.append(tdir)
@@ -809,7 +809,7 @@ class cmd_lava_test_shell(BaseAction):
rdir = self.context.host_result_dir
parse_err_msg = None
- with target.file_system(results_part, 'lava') as d:
+ with target.file_system(results_part, target.lava_test_dir) as d:
err_log = os.path.join(d, 'parse_err.log')
results_dir = os.path.join(d, 'results')
bundle = lava_test_shell.get_bundle(results_dir, testdef_objs, err_log)
diff --git a/lava_dispatcher/client/lmc_utils.py b/lava_dispatcher/client/lmc_utils.py
index 957a30b..1cfa03d 100644
--- a/lava_dispatcher/client/lmc_utils.py
+++ b/lava_dispatcher/client/lmc_utils.py
@@ -122,6 +122,7 @@ def image_partition_mounted(image_file, partno):
try:
yield mntdir
finally:
+ logging_system('sync')
logging_system('sudo umount ' + mntdir)
logging_system('rm -rf ' + mntdir)
diff --git a/lava_dispatcher/config.py b/lava_dispatcher/config.py
index 899995b..b722ccf 100644
--- a/lava_dispatcher/config.py
+++ b/lava_dispatcher/config.py
@@ -51,6 +51,7 @@ class DeviceSchema(schema.Schema):
cache_part_android_org = schema.IntOption()
client_type = schema.StringOption()
connection_command = schema.StringOption(fatal=True)
+ connection_command_pattern = schema.StringOption(default="Connected\.\r")
data_part_android = schema.IntOption()
data_part_android_org = schema.IntOption()
default_network_interface = schema.StringOption()
@@ -91,6 +92,7 @@ class DeviceSchema(schema.Schema):
tester_ps1_includes_rc = schema.StringOption(null=True)
tester_rc_cmd = schema.StringOption(null=True)
+ lava_test_dir = schema.StringOption(null=True)
val = schema.StringOption()
sdcard_mountpoint_path = schema.StringOption(default="/storage/sdcard0")
possible_partitions_files = schema.ListOption(default=["init.partitions.rc",
diff --git a/lava_dispatcher/default-config/lava-dispatcher/device-types/amarillo.conf b/lava_dispatcher/default-config/lava-dispatcher/device-types/amarillo.conf
new file mode 100644
index 0000000..4b20cf1
--- /dev/null
+++ b/lava_dispatcher/default-config/lava-dispatcher/device-types/amarillo.conf
@@ -0,0 +1,28 @@
+client_type = bootloader
+
+bootloader_prompt = =>
+
+pre_boot_cmd = clear
+
+boot_cmds_tftp =
+ setenv bootm_high 0x20000000,
+ setenv bootm_low 0x10000000,
+ setenv ethact LSI_FEMAC,
+ setenv fdt_high 0xffffffff,
+ setenv loadaddr 4000000,
+ setenv macspeed 100MF,
+ setenv autoload no,
+ setenv fdt_high "'0xffffffff'",
+ setenv loadkernel "'tftp ${addr_kern} ${lava_kernel}'",
+ setenv nfsargs "'setenv bootargs root=/dev/nfs rw nfsroot=${lava_server_ip}:${lava_nfsrootfs} console=ttyAMA0 ip=dhcp'",
+ setenv bootcmd "'dhcp; setenv serverip ${lava_server_ip}; run loadkernel; run nfsargs; bootm 4000000'",
+ boot
+
+boot_cmds =
+ boot
+
+boot_options =
+ boot_cmds
+
+[boot_cmds]
+default = boot_cmds
diff --git a/lava_dispatcher/default-config/lava-dispatcher/device-types/imx6q-wandboard.conf b/lava_dispatcher/default-config/lava-dispatcher/device-types/imx6q-wandboard.conf
new file mode 100644
index 0000000..73bc45f
--- /dev/null
+++ b/lava_dispatcher/default-config/lava-dispatcher/device-types/imx6q-wandboard.conf
@@ -0,0 +1,21 @@
+client_type = bootloader
+
+boot_cmds_tftp =
+ setenv autoload no,
+ setenv kernel_addr_r "'0x10800000'",
+ setenv fdt_addr_r "'0x11000000'",
+ setenv loadkernel "'tftp ${kernel_addr_r} ${lava_kernel}'",
+ setenv loadfdt "'tftp ${fdt_addr_r} ${lava_dtb}'",
+ setenv nfsargs "'setenv bootargs console=ttymxc0,115200 root=/dev/nfs rw nfsroot=${lava_server_ip}:${lava_nfsrootfs} ip=:::::eth0:dhcp'",
+ setenv bootcmd "'dhcp; setenv serverip ${lava_server_ip}; run loadkernel; run loadfdt; run nfsargs; bootz ${kernel_addr_r} - ${fdt_addr_r}'",
+ boot
+
+bootloader_prompt = =>
+
+interrupt_boot_prompt = autoboot
+
+boot_options =
+ boot_cmds
+
+[boot_cmds]
+default = boot_cmds
diff --git a/lava_dispatcher/default-config/lava-dispatcher/device-types/xi3.conf b/lava_dispatcher/default-config/lava-dispatcher/device-types/xi3.conf
index c54c7de..d431663 100644
--- a/lava_dispatcher/default-config/lava-dispatcher/device-types/xi3.conf
+++ b/lava_dispatcher/default-config/lava-dispatcher/device-types/xi3.conf
@@ -11,6 +11,8 @@ interrupt_boot_prompt = Hit any key to stop autoboot
busybox_http_port = 8080
+lava_test_dir = /tmp/lava
+
boot_cmds_tftp =
dhcp,
setenv serverip ${lava_server_ip},
diff --git a/lava_dispatcher/device/bootloader.py b/lava_dispatcher/device/bootloader.py
index 6ee0754..810efc8 100644
--- a/lava_dispatcher/device/bootloader.py
+++ b/lava_dispatcher/device/bootloader.py
@@ -232,7 +232,7 @@ class BootloaderTarget(MasterImageTarget):
incrc = self.tester_ps1_includes_rc
runner = NetworkCommandRunner(self, pat, incrc)
- targetdir = '/%s' % directory
+ targetdir = os.path.join('/', directory)
runner.run('mkdir -p %s' % targetdir)
parent_dir, target_name = os.path.split(targetdir)
runner.run('/bin/tar -cmzf /tmp/fs.tgz -C %s %s'
diff --git a/lava_dispatcher/device/target.py b/lava_dispatcher/device/target.py
index bb91350..c72f137 100644
--- a/lava_dispatcher/device/target.py
+++ b/lava_dispatcher/device/target.py
@@ -319,10 +319,21 @@ class Target(object):
def tester_rc_cmd(self):
return self._get_from_config_or_deployment_data('tester_rc_cmd')
+ @property
+ def lava_test_dir(self):
+ return self._get_from_config_or_deployment_data('lava_test_dir')
+
def _get_from_config_or_deployment_data(self, key):
value = getattr(self.config, key.lower())
if value is None:
- return self.deployment_data.get(key.upper())
+ keys = [key, key.upper(), key.lower()]
+ for test_key in keys:
+ value = self.deployment_data.get(test_key)
+ if value is not None:
+ return value
+
+ # At this point we didn't find anything.
+ raise KeyError("Unable to find value for key %s" % key)
else:
return value
diff --git a/lava_test_shell/README b/lava_dispatcher/lava_test_shell/README
index 4868b21..4868b21 100644
--- a/lava_test_shell/README
+++ b/lava_dispatcher/lava_test_shell/README
diff --git a/lava_test_shell/distro/android/lava-test-runner b/lava_dispatcher/lava_test_shell/distro/android/lava-test-runner
index 6fc5f0d..6fc5f0d 100755
--- a/lava_test_shell/distro/android/lava-test-runner
+++ b/lava_dispatcher/lava_test_shell/distro/android/lava-test-runner
diff --git a/lava_test_shell/distro/fedora/lava-install-packages b/lava_dispatcher/lava_test_shell/distro/fedora/lava-install-packages
index b463208..b463208 100644
--- a/lava_test_shell/distro/fedora/lava-install-packages
+++ b/lava_dispatcher/lava_test_shell/distro/fedora/lava-install-packages
diff --git a/lava_test_shell/distro/fedora/lava-installed-packages b/lava_dispatcher/lava_test_shell/distro/fedora/lava-installed-packages
index 40556ad..40556ad 100644
--- a/lava_test_shell/distro/fedora/lava-installed-packages
+++ b/lava_dispatcher/lava_test_shell/distro/fedora/lava-installed-packages
diff --git a/lava_test_shell/distro/fedora/lava-os-build b/lava_dispatcher/lava_test_shell/distro/fedora/lava-os-build
index f01bf81..f01bf81 100644
--- a/lava_test_shell/distro/fedora/lava-os-build
+++ b/lava_dispatcher/lava_test_shell/distro/fedora/lava-os-build
diff --git a/lava_test_shell/distro/ubuntu/lava-install-packages b/lava_dispatcher/lava_test_shell/distro/ubuntu/lava-install-packages
index 011038f..011038f 100644
--- a/lava_test_shell/distro/ubuntu/lava-install-packages
+++ b/lava_dispatcher/lava_test_shell/distro/ubuntu/lava-install-packages
diff --git a/lava_test_shell/distro/ubuntu/lava-installed-packages b/lava_dispatcher/lava_test_shell/distro/ubuntu/lava-installed-packages
index 125c316..125c316 100644
--- a/lava_test_shell/distro/ubuntu/lava-installed-packages
+++ b/lava_dispatcher/lava_test_shell/distro/ubuntu/lava-installed-packages
diff --git a/lava_test_shell/distro/ubuntu/lava-os-build b/lava_dispatcher/lava_test_shell/distro/ubuntu/lava-os-build
index d5e3720..d5e3720 100644
--- a/lava_test_shell/distro/ubuntu/lava-os-build
+++ b/lava_dispatcher/lava_test_shell/distro/ubuntu/lava-os-build
diff --git a/lava_test_shell/lava-installed-packages b/lava_dispatcher/lava_test_shell/lava-installed-packages
index 8b4b11e..8b4b11e 100644
--- a/lava_test_shell/lava-installed-packages
+++ b/lava_dispatcher/lava_test_shell/lava-installed-packages
diff --git a/lava_test_shell/lava-os-build b/lava_dispatcher/lava_test_shell/lava-os-build
index f0030c9..f0030c9 100644
--- a/lava_test_shell/lava-os-build
+++ b/lava_dispatcher/lava_test_shell/lava-os-build
diff --git a/lava_test_shell/lava-test-case b/lava_dispatcher/lava_test_shell/lava-test-case
index 6cebdcb..6cebdcb 100644
--- a/lava_test_shell/lava-test-case
+++ b/lava_dispatcher/lava_test_shell/lava-test-case
diff --git a/lava_test_shell/lava-test-case-attach b/lava_dispatcher/lava_test_shell/lava-test-case-attach
index e69985a..e69985a 100644
--- a/lava_test_shell/lava-test-case-attach
+++ b/lava_dispatcher/lava_test_shell/lava-test-case-attach
diff --git a/lava_test_shell/lava-test-run-attach b/lava_dispatcher/lava_test_shell/lava-test-run-attach
index d6c3f98..d6c3f98 100644
--- a/lava_test_shell/lava-test-run-attach
+++ b/lava_dispatcher/lava_test_shell/lava-test-run-attach
diff --git a/lava_test_shell/lava-test-runner b/lava_dispatcher/lava_test_shell/lava-test-runner
index 7a61d30..e798564 100755
--- a/lava_test_shell/lava-test-runner
+++ b/lava_dispatcher/lava_test_shell/lava-test-runner
@@ -1,9 +1,17 @@
#!/bin/sh
+if [ "$1" = "" ]
+then
+ LAVA_PATH="/lava"
+else
+ LAVA_PATH=$1
+fi
+
+echo $LAVA_PATH
PREFIX="<LAVA_TEST_RUNNER>:"
-WORKFILE="/lava/lava-test-runner.conf"
-RESULTSDIR="/lava/results"
-BINDIR="/lava/bin"
+WORKFILE="$LAVA_PATH/lava-test-runner.conf"
+RESULTSDIR="$LAVA_PATH/results"
+BINDIR="$LAVA_PATH/bin"
hwcontext()
{
diff --git a/lava_test_shell/lava-test-shell b/lava_dispatcher/lava_test_shell/lava-test-shell
index 03ac76b..03ac76b 100755
--- a/lava_test_shell/lava-test-shell
+++ b/lava_dispatcher/lava_test_shell/lava-test-shell
diff --git a/lava_test_shell/lmp/lava-lmp-audio-jack b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-audio-jack
index 2d82f4c..2d82f4c 100644
--- a/lava_test_shell/lmp/lava-lmp-audio-jack
+++ b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-audio-jack
diff --git a/lava_test_shell/lmp/lava-lmp-eth b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-eth
index 491f3c0..491f3c0 100644
--- a/lava_test_shell/lmp/lava-lmp-eth
+++ b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-eth
diff --git a/lava_test_shell/lmp/lava-lmp-hdmi b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-hdmi
index 7800bdb..7800bdb 100644
--- a/lava_test_shell/lmp/lava-lmp-hdmi
+++ b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-hdmi
diff --git a/lava_test_shell/lmp/lava-lmp-lsgpio b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-lsgpio
index edf905d..edf905d 100644
--- a/lava_test_shell/lmp/lava-lmp-lsgpio
+++ b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-lsgpio
diff --git a/lava_test_shell/lmp/lava-lmp-sata b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-sata
index dd3f54b..dd3f54b 100644
--- a/lava_test_shell/lmp/lava-lmp-sata
+++ b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-sata
diff --git a/lava_test_shell/lmp/lava-lmp-usb b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-usb
index 82fcafb..82fcafb 100644
--- a/lava_test_shell/lmp/lava-lmp-usb
+++ b/lava_dispatcher/lava_test_shell/lmp/lava-lmp-usb
diff --git a/lava_test_shell/lmp/lava-lmp.lib b/lava_dispatcher/lava_test_shell/lmp/lava-lmp.lib
index 7d15649..7d15649 100644
--- a/lava_test_shell/lmp/lava-lmp.lib
+++ b/lava_dispatcher/lava_test_shell/lmp/lava-lmp.lib
diff --git a/lava_test_shell/multi_node/lava-group b/lava_dispatcher/lava_test_shell/multi_node/lava-group
index 1dabc2a..1dabc2a 100644
--- a/lava_test_shell/multi_node/lava-group
+++ b/lava_dispatcher/lava_test_shell/multi_node/lava-group
diff --git a/lava_test_shell/multi_node/lava-multi-node.lib b/lava_dispatcher/lava_test_shell/multi_node/lava-multi-node.lib
index 01017c1..01017c1 100644
--- a/lava_test_shell/multi_node/lava-multi-node.lib
+++ b/lava_dispatcher/lava_test_shell/multi_node/lava-multi-node.lib
diff --git a/lava_test_shell/multi_node/lava-network b/lava_dispatcher/lava_test_shell/multi_node/lava-network
index 0f67290..0f67290 100644
--- a/lava_test_shell/multi_node/lava-network
+++ b/lava_dispatcher/lava_test_shell/multi_node/lava-network
diff --git a/lava_test_shell/multi_node/lava-role b/lava_dispatcher/lava_test_shell/multi_node/lava-role
index 53568c1..53568c1 100644
--- a/lava_test_shell/multi_node/lava-role
+++ b/lava_dispatcher/lava_test_shell/multi_node/lava-role
diff --git a/lava_test_shell/multi_node/lava-self b/lava_dispatcher/lava_test_shell/multi_node/lava-self
index e792d96..e792d96 100644
--- a/lava_test_shell/multi_node/lava-self
+++ b/lava_dispatcher/lava_test_shell/multi_node/lava-self
diff --git a/lava_test_shell/multi_node/lava-send b/lava_dispatcher/lava_test_shell/multi_node/lava-send
index 9011c30..9011c30 100644
--- a/lava_test_shell/multi_node/lava-send
+++ b/lava_dispatcher/lava_test_shell/multi_node/lava-send
diff --git a/lava_test_shell/multi_node/lava-sync b/lava_dispatcher/lava_test_shell/multi_node/lava-sync
index ae49a92..ae49a92 100644
--- a/lava_test_shell/multi_node/lava-sync
+++ b/lava_dispatcher/lava_test_shell/multi_node/lava-sync
diff --git a/lava_test_shell/multi_node/lava-wait b/lava_dispatcher/lava_test_shell/multi_node/lava-wait
index c5c6785..c5c6785 100644
--- a/lava_test_shell/multi_node/lava-wait
+++ b/lava_dispatcher/lava_test_shell/multi_node/lava-wait
diff --git a/lava_test_shell/multi_node/lava-wait-all b/lava_dispatcher/lava_test_shell/multi_node/lava-wait-all
index 120f7a9..120f7a9 100644
--- a/lava_test_shell/multi_node/lava-wait-all
+++ b/lava_dispatcher/lava_test_shell/multi_node/lava-wait-all
diff --git a/lava_dispatcher/utils.py b/lava_dispatcher/utils.py
index 653e948..3fe6fa6 100644
--- a/lava_dispatcher/utils.py
+++ b/lava_dispatcher/utils.py
@@ -246,7 +246,7 @@ def connect_to_serial(context):
expectations = {
port_stuck_message: 'reset-port',
- 'Connected\.\r': 'all-good',
+ context.device_config.connection_command_pattern: 'all-good',
conn_closed_message: 'retry',
pexpect.TIMEOUT: 'all-good',
}
diff --git a/setup.py b/setup.py
index 12f5cab..c44bb91 100755
--- a/setup.py
+++ b/setup.py
@@ -32,10 +32,6 @@ setup(
'default-config/lava-dispatcher/device-types/*.conf',
'default-config/lava-dispatcher/devices/*.conf',
'device/sdmux.sh',
- ],
- },
- data_files=[
- ('lava_test_shell', [
'lava_test_shell/lava-installed-packages',
'lava_test_shell/lava-os-build',
'lava_test_shell/lava-test-case',
@@ -43,25 +39,13 @@ setup(
'lava_test_shell/lava-test-run-attach',
'lava_test_shell/lava-test-runner',
'lava_test_shell/lava-test-shell',
- 'lava_test_shell/README']),
- ('lava_test_shell/multi_node', [
- 'lava_test_shell/multi_node/lava-group',
- 'lava_test_shell/multi_node/lava-multi-node.lib',
- 'lava_test_shell/multi_node/lava-role',
- 'lava_test_shell/multi_node/lava-self',
- 'lava_test_shell/multi_node/lava-send',
- 'lava_test_shell/multi_node/lava-sync',
- 'lava_test_shell/multi_node/lava-wait',
- 'lava_test_shell/multi_node/lava-wait-all']),
- ('lava_test_shell/lmp', [
- 'lava_test_shell/lmp/lava-lmp-audio-jack',
- 'lava_test_shell/lmp/lava-lmp-eth',
- 'lava_test_shell/lmp/lava-lmp-hdmi',
- 'lava_test_shell/lmp/lava-lmp.lib',
- 'lava_test_shell/lmp/lava-lmp-lsgpio',
- 'lava_test_shell/lmp/lava-lmp-sata',
- 'lava_test_shell/lmp/lava-lmp-usb'])
- ],
+ 'lava_test_shell/multi_node/*',
+ 'lava_test_shell/lmp/*',
+ 'lava_test_shell/distro/fedora/*',
+ 'lava_test_shell/distro/android/*',
+ 'lava_test_shell/distro/ubuntu/*',
+ ],
+ },
install_requires=[
'json-schema-validator >= 2.3',
'lava-tool >= 0.4',