summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2016-12-06Run Avocado tests on odroid and minnowAleksander Mistewicz3-0/+26
Change-Id: I438d266802b9d9b29e4dd3f7314f3ec1f5776fca Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add run_avocado_sdb() to tct/run/run.shAleksander Mistewicz1-0/+15
Change-Id: I656c7302ed5fbf79b277890920b9d93b897eeb9d Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add run_avocado_ssh() to tct/run/run.shAleksander Mistewicz1-0/+17
Change-Id: Id3ede4bad3079cb95404a5f733dcc67b62fb087d Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add tsp/common_test.yaml.exampleAleksander Mistewicz1-0/+18
Run: avocado run tct/run/common_test.py \ --multiplex tsp/common_test.yaml.example Change-Id: Ie90e774e410626ccfca33ab262f85e5bd71b59ec Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add SDB support to tct/run/common_test.pyAleksander Mistewicz1-8/+29
Change-Id: Ic5a135a2763762cacbd0d756e1dea077d545204d Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add avocado testscript: tct/run/common_test.pyAleksander Mistewicz1-0/+88
Change-Id: I2d0bb33c99a2672175fd06ccc19bd0720ebde1d2 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Preserve SSH session between callsAleksander Mistewicz1-0/+3
Connection time to DUT averages to 28s. After first call each subsequent is near instant. Change-Id: I4fe50406fec06a7468d0e904295a4f7669803b2d Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Use WS instead of / in tsp/jobs/watch_diskspace.shAleksander Mistewicz1-3/+2
Manual configuration was required for this script to use proper value. Now it gets it automatically. Change-Id: Icd0881ba05bafe120387f159fbb29c5c604d8a27 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Fix build_nr in tsp/jobs/trigger_downloads.shAleksander Mistewicz1-10/+13
If a url is present in tsmaster queue $i value will be changed to last killed task's number or simply undefined value. Rename $i to $next Add update_next() which checks if write to a file was successful. Append to unique_dispatch instead of overwrite. Change-Id: Ib49c248a0f756a090c2408a7ae60be76dccd707a Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add artik support to tsp/scripts/download_image.pyAleksander Mistewicz1-23/+44
Supported target configurations: * odroid, minnow32, minnow64 (unchanged) * headless-artik5, artik5, headless-artik10, artik10 (new) Change-Id: Idf46f15e633fab34ed8bd9de71934ac2fd3293b8 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06New version of tsp/scripts/download_image.pyAleksander Mistewicz4-96/+79
It breaks backward-compatibility with arguments and results. TSP scripts are adjusted. Supported target configurations (unchanged): odroid, minnow32, minnow64 Changes: * now uses target name for project-$target.conf and diff-$target.report * old arguments are replaced by one "-t TARGET" Change-Id: I0d503717c09073d72cb742fcc024247ec807896a Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Fix issues reported by ShellCheck in tctAleksander Mistewicz15-32/+32
ShellCheck: https://github.com/koalaman/shellcheck Command below should not print anything. shellcheck -e SC2164,SC1090,SC2148,SC2010,SC2155,SC2024,SC2086,SC2044 \ $(find tct -name "*.sh") Change-Id: I30d7db0bdd1370d8010b8adbea76bf65f2e07373 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Fix issues reported by ShellCheck in tspAleksander Mistewicz13-86/+94
Move check_diff() to tsp/jobs/img_test_common.sh Add newline at the end of 'modifed_paths' in tsp/scripts/crawler.py so that whole lines instead of words can be read. ShellCheck: https://github.com/koalaman/shellcheck shellcheck -e SC1090,SC2155,SC2068,SC2145,SC2164 `find tsp -name "*.sh"` output should report following problems only: tsp/common.sh: SC2148, SC2034, SC2139 tsp/jobs/trigger_downloads.sh: SC2115 tsp/jobs/common_prep_flash_conf.sh: SC2029 tsp/jobs/publish.sh: SC2046, SC2029 Change-Id: I7791769a0d653c784715cdd1a8b1446fafcba1e9 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add test/tct_prepare.batsAleksander Mistewicz1-0/+70
mkfs.ext4 is required. It does not check error paths. Change-Id: I54477a575350d9c70d8413a9243a72d3fa27e25c Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add test/tct_sdmux.batsAleksander Mistewicz1-0/+36
Exactly one sdmux device should be connected during these tests. Change-Id: I48c098cc02416e52067fe5b2bfe23da5e9c78463 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add test/tct_common.batsAleksander Mistewicz1-0/+27
Change-Id: I80c9ae848873742a0521e6c4aa29c8f8d138bb69 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add test/resource_locking.py.batsAleksander Mistewicz1-0/+89
Change-Id: I7ea1e13702ea17488da6c2c0424db1283d7f4db2 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add tsp/stop.shAleksander Mistewicz2-2/+76
To stop TITS run: ./tsp/stop.sh Steps are: * remove crontab * save currently dispatched urls * for tsmaster, tspoll, tspwb: ** remove queued jobs ** kill running jobs ** kill the server * for tsrun_target queues: ** remove queued jobs ** wait for running jobs ** kill the server To start TITS run: crontab tsp/cronfile.example Change-Id: I051a9ddcec0093c1fae3888ec9a9b438b73f5bb3 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Add tsp/tsp-sudoerAleksander Mistewicz1-0/+29
Syntax error in any file used by sudo will break it. Always check it as in example below: visudo -c -f tsp/tsp-sudoer Change-Id: Icb7978c31370924d1f1928a711de86283022aa4c Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Do not run sshpass and sd-mux-ctrl as rootAleksander Mistewicz3-7/+7
When using sshpass in a container special privileges were required. It is no longer the case as TITS should run bare metal. User should be member of 'plugdev' group. Change-Id: I785c262dae9d78bc0b07759ba6e29df1fe744adc Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Check for ssh errors in common_prep_flash_conf.shAleksander Mistewicz2-18/+41
Change-Id: I3850233b5459d5d4bf075cdad37f94020ca7641c Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-12-06Update tsp/scripts/free_diskspace.shAleksander Mistewicz1-4/+10
Only directories, modified at least 2 days ago, in WS_DOWNLOAD are processed. All non-snapshot directories are verbosely removed. Change-Id: Ibabb7d874e1e75453c8f348725b99346007e1908 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-11-08Replace sqlite3 html output with python scriptAleksander Mistewicz1-1/+1
Change-Id: I137be0324c7b783c191e8e6abdc8a83139a80777 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-11-08Add tsp/scripts/publish.pyAleksander Mistewicz1-0/+82
This script requires jinja2 templating library. Change-Id: Icd30ab726bc98a7e6556363c4a3bf8eccbdfa7a7 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-11-08Add "tbuildnr" field to results.db3Aleksander Mistewicz2-6/+8
Previous database should be removed or updated as below: . tsp/common.sh sqlite3 "${DBPATH}" "ALTER TABLE test ADD COLUMN tbuildnr INTEGER;" View must be dropped and redefined: sqlite3 "${DBPATH}" "DROP VIEW currentstatus;" sqlite3 "${DBPATH}" -batch < tsp/results-schema.sql Change-Id: Ic04a2c050468064ed3c9b8ac0ab3db4af075cbc1 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-11-08Publish database content in WWW_PUBLISH fileAleksander Mistewicz4-0/+27
Change-Id: Ic8f05d856b5001eb4ffe83f76c9f6a30ae79da11 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-11-08Store results in sqlite3 databaseAleksander Mistewicz4-7/+39
Additional argument, $TARGET, is required for tsp/jobs/publish.sh Change-Id: Iab5728c40e4786425c26dd48e7a70d6221dc90ae Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-11-02Add schema and initial values for sqlite3 dbAleksander Mistewicz3-0/+38
tsp/results-schema.sql contains basic table definitions of device, result, test and "currentstatus" view. Change-Id: I53c5a7e5d744aba07500ef5492c490368692cb44 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-11-02Compare result with snapshot and assign proper tagAleksander Mistewicz1-3/+95
Tag is from set: OK, Identical, Snapshot, Unclear, Fail Change-Id: Ieac636e4b4d00aa21ec86253beb4e7cc38694ec3 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-11-02Dump variable name and value to sysctl.result fileAleksander Mistewicz5-7/+20
tct/run/smoke_tests.sh produces some numerical output. This patch makes it easy to store and retreive values as in line below: awk -v KEY="${KEY}" '$1 == KEY {print $2}' $DICT where $KEY is variable name and $DICT is sysctl.result file. Change-Id: I3eee61152a189ad443fa641f5160f516567506f1 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Set TS_SLOTS for every queueAleksander Mistewicz1-4/+4
Change-Id: I4e1a7e5964985957e34ad151c031c982cd814219 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Update md5sums logic in tsp/scripts/crawler.pyAleksander Mistewicz1-7/+13
If any of the md5sums_url is missing (http error code 404 was returned) from md5sums_urls list then it will be skipped and not dispatched. It saves http requests so that it won't timeout if the server is busy. For url to be added to dispatched_urls it must: * have every md5sums_url from md5sums_urls list available (no 404 error returned) * have any of the md5sums_urls modified since last timestamp Change-Id: Ie790f1039e91003b0da85c19d7db11ac160007da Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Fix missing mountpoint directory in mount_image()Aleksander Mistewicz2-2/+2
Remove redundant mkdirs from tct/odroid_prepare_flash_conf.sh Change-Id: I6da51ef4b7e82debf66eea88570b7e997bf7855a Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Log every finished job to /tmp/testlab.logAleksander Mistewicz3-1/+4
Add quiet param to wget in tsp/scripts/download_image.py Add tsp/scripts/log.sh which writes all its params to /tmp/testlab.log Add env variable in tsp/common.sh: TS_ONFINISH if TSP_DIR is set Change-Id: I87510f3fe73dc20d1842075cdf77186b8d298581 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Use TMPDIR instead of TS_SOCKET in tsp/common.shAleksander Mistewicz1-5/+15
Usage of patched version of tsp is advised, but not necessary. In unpatched version output file is stored in "/tmp" directory regardless of TMPDIR value. Change-Id: If03cff1b83c3e4762efc82ff93a439e8b52e09f2 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Write new timestamp at the end in crawl.pyAleksander Mistewicz1-2/+2
If a timeout occurs during a crawl an old timestamp will be preserved. Change-Id: Ibae158baa1a8c8fbe09397225b312d29d44e715c Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Use logging in tsp/scripts/crawler.pyAleksander Mistewicz2-2/+21
Change-Id: Ie18cfe89cc4c7149ba0f53b6227d1e0d1dd818bc Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Replace env variable with argparse in crawler.pyAleksander Mistewicz2-31/+42
Change-Id: I4a299d124df4692670d46726177073980aefdc88 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Add timeout to remote script run and watcherAleksander Mistewicz2-3/+3
Change-Id: I6713f6bbfba3aecf6108e01f21de709f3eadd0be Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Add timeout to copy_ssh and run_smoke_sshAleksander Mistewicz2-2/+2
Change-Id: I64e6f8643cda4e89b5b35b0d472fb548ec3320c8 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Remove magic HOLDOFF number in resource_locking.pyAleksander Mistewicz1-5/+10
Change-Id: I56cf4cadb695bc12b5494f4fab404ab8905af733 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Remove magic INC number in resource_locking.pyAleksander Mistewicz1-5/+10
Change-Id: I25ada81e4f2224f8ec23d43c960ff435ad201397 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Check for UUID files in tct/resource_locking.pyAleksander Mistewicz1-2/+17
Change-Id: Ib593cf3958392807d05d6c07cecb27c93024f581 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Use new version of tct/resource_locking scriptAleksander Mistewicz1-8/+7
Change-Id: Ie684ba0aecf2f6ab76da3a9a95560d29c6c4c549 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Add "--unlockfailed" to tct/resource_locking.pyAleksander Mistewicz1-0/+13
Change-Id: I6c00f39d69fcf617c0dcbfb266335c5b44a29604 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Add count files to tct/resource_locking.pyAleksander Mistewicz1-2/+34
Change-Id: Ie06d890490a66616d909f7953c04e3c86df62a95 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Add "--retrylock" to tct/resource_locking.pyAleksander Mistewicz1-0/+12
Change-Id: I9445f87d19db642c14487c8bde11b48764f1656e Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Add "--unlock" to tct/resource_locking.pyAleksander Mistewicz1-1/+17
Change-Id: Ib7f21dab314eca65a7ee4a0c85a66f0cce02af05 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-10-07Add "--lock" to tct/resource_locking.pyAleksander Mistewicz1-0/+28
"target" argument is now mandatory. Change-Id: I6dbcd586da1320ee1ee20f131e8290c4e06fdb13 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>
2016-09-26Add tct/resource_locking.pyAleksander Mistewicz1-0/+104
Change-Id: I8420edfdc606544bbc41bee93cd314d39e8048b1 Signed-off-by: Aleksander Mistewicz <a.mistewicz@samsung.com>