diff options
author | Wolfram Sang <w.sang@pengutronix.de> | 2009-05-18 13:51:36 +0000 |
---|---|---|
committer | Wolfram Sang <w.sang@pengutronix.de> | 2009-05-18 13:51:36 +0000 |
commit | d39a98728c7c341a706081a395618ca1cc41cd55 (patch) | |
tree | deb0de1545dc61fe67c242fdc446069855806624 /tests | |
parent | 1e84c54fcd41c77684314538551ea08b9fcfca96 (diff) | |
download | ptxdist-d39a98728c7c341a706081a395618ca1cc41cd55.tar.gz ptxdist-d39a98728c7c341a706081a395618ca1cc41cd55.tar.xz |
* tests: - add 20yy.m to u-boot v1 signatures
- relax match for u-boot v2 results, because of EOL confusions
git-svn-id: https://svn.pengutronix.de/svn/ptxdist/trunks/ptxdist-trunk@10538 33e552b5-05e3-0310-8538-816dae2090ed
Diffstat (limited to 'tests')
-rw-r--r-- | tests/libptxdisttest.kermit | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/tests/libptxdisttest.kermit b/tests/libptxdisttest.kermit index 915d9ea4a..5a419780a 100644 --- a/tests/libptxdisttest.kermit +++ b/tests/libptxdisttest.kermit @@ -88,20 +88,23 @@ define ptx_uboot_enter_shell { ptx_test_start "Logging into U-Boot" - minput 120 "U-Boot 1" "U-Boot 2" + # Determine U-Boot version; 20yy.m is treated as V1. + # tried to match all V1 signatures with \fpattern, failed badly :( + minput 120 "U-Boot 1." "U-Boot 2." "U-Boot 20" :eval_again ptx_check_fail "waiting for u-boot-signature" lineout - .uboot_version := \v(minput) - if = \m(uboot_version) 2 { + if = \v(minput) 2 { .uboot_prompt = "uboot:" + .uboot_version = 2 } else { - .uboot_prompt = "uboot> " + .uboot_prompt = "uboot>" + .uboot_version = 1 } # sometimes there are caches for serial inputs containing old data # make sure we act on the newest one - minput 120 "U-Boot 1" "U-Boot 2" \m(uboot_prompt) - if not = \v(minput) 3 goto eval_again + minput 120 "U-Boot 1." "U-Boot 2." "U-Boot 20" \m(uboot_prompt) + if not = \v(minput) 4 goto eval_again ptx_test_end } @@ -115,10 +118,8 @@ define ptx_uboot_exec { if = \m(uboot_version) 2 { ptx_lineout "echo result: $?" - input 10 \fpattern(^result: 0$) - + input 10 \fpattern(result: 0) ptx_check_fail "returncode from '\%2' is not 0" - input 10 \m(uboot_prompt) } } |