From: David Gibson <david@gibson.dropbear.id.au>
To: Jon Loeliger <jdl@freescale.com>
Cc: linuxppc-dev@ozlabs.org
Subject: libfdt: Test rw functions on more trees
Date: Fri, 28 Sep 2007 14:57:01 +1000 [thread overview]
Message-ID: <20070928045701.GB25743@localhost.localdomain> (raw)
At present, the testcases for read/write functions (setprop,
del_property and del_node) are only invoked on the single
asm-generated tree, not on any of the other tree images which should
be equivalent. The functions in question will (correctly) not work on
the "unfinished" tree output from sw_tree1, but should work on most of
the others.
This patch extends the run_tests script to invoke the r/w testcases on
more example trees. The testsuite still passes clean with this
addition.
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Index: dtc/tests/run_tests.sh
===================================================================
--- dtc.orig/tests/run_tests.sh 2007-09-27 17:49:29.000000000 +1000
+++ dtc/tests/run_tests.sh 2007-09-27 17:57:00.000000000 +1000
@@ -49,6 +49,15 @@ tree1_tests () {
run_test nop_node $TREE
}
+tree1_tests_rw () {
+ TREE=$1
+
+ # Read-write tests
+ run_test setprop $TREE
+ run_test del_property $TREE
+ run_test del_node $TREE
+}
+
libfdt_tests () {
# Make sure we don't have stale blobs lying around
rm -f *.test.dtb
@@ -76,11 +85,16 @@ libfdt_tests () {
tree1_tests opened.$tree
tree1_tests repacked.$tree
done
- run_test setprop test_tree1.dtb
- run_test del_property test_tree1.dtb
- run_test del_node test_tree1.dtb
+
+ for tree in test_tree1.dtb sw_tree1.test.dtb; do
+ tree1_tests_rw $tree
+ tree1_tests_rw moved.$tree
+ tree1_tests_rw shunted.$tree
+ tree1_tests_rw deshunted.$tree
+ done
run_test rw_tree1
tree1_tests rw_tree1.test.dtb
+ tree1_tests_rw rw_tree1.test.dtb
# Tests for behaviour on various sorts of corrupted trees
run_test truncated_property
@@ -92,6 +106,7 @@ dtc_tests () {
run_test dtc.sh -f -I dts -O dtb -o dtc_tree1.test.dtb test_tree1.dts
tree1_tests dtc_tree1.test.dtb
+ tree1_tests_rw dtc_tree1.test.dtb
}
while getopts "vdt:" ARG ; do
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
next reply other threads:[~2007-09-28 4:57 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-09-28 4:57 David Gibson [this message]
2007-10-15 13:34 ` libfdt: Test rw functions on more trees Jon Loeliger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070928045701.GB25743@localhost.localdomain \
--to=david@gibson.dropbear.id.au \
--cc=jdl@freescale.com \
--cc=linuxppc-dev@ozlabs.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).