diff options
author | Jiajun Xu <jiajun.xu@intel.com> | 2011-05-03 10:07:30 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2011-05-04 00:56:33 +0100 |
commit | ea4857a98b500e0b73d875b28c43e2d1d0f740b6 (patch) | |
tree | 23cbe4dab67160a869b2689949720b10de1a3c99 /scripts/qemuimage-tests | |
parent | 49e2fcc60458853d7ff7f2908e695b11a95f3061 (diff) | |
download | poky-ea4857a98b500e0b73d875b28c43e2d1d0f740b6.tar.gz |
qemuimagetest: Enable toolchain automation tests in qemuimagetest
Enable toolchain automation tests in qemuimagetest framework. 3 C/C++ test
projects are added to test toolchain - cvs, iptables and sudoku-savant. User
needs to set TEST_SCEN to "toolchain" in local.conf to enable tests. Test case
will check if toolchain tarball exists under "${DEPLOY_DIR}/sdk". And it will
extract toolchain tarball into /opt. It requires user to chown /opt to non-root
user, who will run qemuimagetest.
Signed-off-by Jiajun Xu <jiajun.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/qemuimage-tests')
8 files changed, 108 insertions, 0 deletions
diff --git a/scripts/qemuimage-tests/scenario/qemuarm/meta-toolchain-gmae b/scripts/qemuimage-tests/scenario/qemuarm/meta-toolchain-gmae new file mode 100644 index 0000000000..199176efc8 --- /dev/null +++ b/scripts/qemuimage-tests/scenario/qemuarm/meta-toolchain-gmae | |||
@@ -0,0 +1,3 @@ | |||
1 | toolchain cvs | ||
2 | toolchain iptables | ||
3 | toolchain sudoku-savant | ||
diff --git a/scripts/qemuimage-tests/scenario/qemumips/meta-toolchain-gmae b/scripts/qemuimage-tests/scenario/qemumips/meta-toolchain-gmae new file mode 100644 index 0000000000..199176efc8 --- /dev/null +++ b/scripts/qemuimage-tests/scenario/qemumips/meta-toolchain-gmae | |||
@@ -0,0 +1,3 @@ | |||
1 | toolchain cvs | ||
2 | toolchain iptables | ||
3 | toolchain sudoku-savant | ||
diff --git a/scripts/qemuimage-tests/scenario/qemuppc/meta-toolchain-gmae b/scripts/qemuimage-tests/scenario/qemuppc/meta-toolchain-gmae new file mode 100644 index 0000000000..199176efc8 --- /dev/null +++ b/scripts/qemuimage-tests/scenario/qemuppc/meta-toolchain-gmae | |||
@@ -0,0 +1,3 @@ | |||
1 | toolchain cvs | ||
2 | toolchain iptables | ||
3 | toolchain sudoku-savant | ||
diff --git a/scripts/qemuimage-tests/scenario/qemux86-64/meta-toolchain-gmae b/scripts/qemuimage-tests/scenario/qemux86-64/meta-toolchain-gmae new file mode 100644 index 0000000000..199176efc8 --- /dev/null +++ b/scripts/qemuimage-tests/scenario/qemux86-64/meta-toolchain-gmae | |||
@@ -0,0 +1,3 @@ | |||
1 | toolchain cvs | ||
2 | toolchain iptables | ||
3 | toolchain sudoku-savant | ||
diff --git a/scripts/qemuimage-tests/scenario/qemux86/meta-toolchain-gmae b/scripts/qemuimage-tests/scenario/qemux86/meta-toolchain-gmae new file mode 100644 index 0000000000..199176efc8 --- /dev/null +++ b/scripts/qemuimage-tests/scenario/qemux86/meta-toolchain-gmae | |||
@@ -0,0 +1,3 @@ | |||
1 | toolchain cvs | ||
2 | toolchain iptables | ||
3 | toolchain sudoku-savant | ||
diff --git a/scripts/qemuimage-tests/toolchain/cvs b/scripts/qemuimage-tests/toolchain/cvs new file mode 100644 index 0000000000..871d99110f --- /dev/null +++ b/scripts/qemuimage-tests/toolchain/cvs | |||
@@ -0,0 +1,31 @@ | |||
1 | #!/bin/bash | ||
2 | # | ||
3 | # CVS compile Test for toolchain test | ||
4 | # The case extract toolchain tarball into temp folder | ||
5 | # Then compile CVS with the toolchain environment | ||
6 | # | ||
7 | # Author: Jiajun Xu <jiajun.xu@intel.com> | ||
8 | # | ||
9 | # This file is licensed under the GNU General Public License, | ||
10 | # Version 2. | ||
11 | # | ||
12 | . $COREBASE/scripts/qemuimage-testlib | ||
13 | |||
14 | TIMEOUT=120 | ||
15 | |||
16 | # Extract and test toolchain tarball | ||
17 | Test_Toolchain cvs ${TIMEOUT} | ||
18 | |||
19 | if [ $? -eq 0 ]; then | ||
20 | Test_Info "CVS Test PASS" | ||
21 | Test_Print_Result "CVS" 0 | ||
22 | exit 0 | ||
23 | elif [ $? -eq 1 ]; then | ||
24 | Test_Info "CVS Test FAIL" | ||
25 | Test_Print_Result "CVS" 1 | ||
26 | exit 1 | ||
27 | else | ||
28 | Test_Info "Skip CVS Test due to some configuration problem" | ||
29 | Test_Print_Result "CVS" 2 | ||
30 | exit 2 | ||
31 | fi | ||
diff --git a/scripts/qemuimage-tests/toolchain/iptables b/scripts/qemuimage-tests/toolchain/iptables new file mode 100644 index 0000000000..af89bbe7b3 --- /dev/null +++ b/scripts/qemuimage-tests/toolchain/iptables | |||
@@ -0,0 +1,31 @@ | |||
1 | #!/bin/bash | ||
2 | # | ||
3 | # iptables compile Test for toolchain test | ||
4 | # The case extract toolchain tarball into temp folder | ||
5 | # Then compile iptables with the toolchain environment | ||
6 | # | ||
7 | # Author: Jiajun Xu <jiajun.xu@intel.com> | ||
8 | # | ||
9 | # This file is licensed under the GNU General Public License, | ||
10 | # Version 2. | ||
11 | # | ||
12 | . $COREBASE/scripts/qemuimage-testlib | ||
13 | |||
14 | TIMEOUT=120 | ||
15 | |||
16 | # Extract and test toolchain tarball | ||
17 | Test_Toolchain iptables ${TIMEOUT} | ||
18 | |||
19 | if [ $? -eq 0 ]; then | ||
20 | Test_Info "iptables Test PASS" | ||
21 | Test_Print_Result "iptables" 0 | ||
22 | exit 0 | ||
23 | elif [ $? -eq 1 ]; then | ||
24 | Test_Info "iptables Test FAIL" | ||
25 | Test_Print_Result "iptables" 1 | ||
26 | exit 1 | ||
27 | else | ||
28 | Test_Info "Skip iptables Test due to some configuration problem" | ||
29 | Test_Print_Result "iptables" 2 | ||
30 | exit 2 | ||
31 | fi | ||
diff --git a/scripts/qemuimage-tests/toolchain/sudoku-savant b/scripts/qemuimage-tests/toolchain/sudoku-savant new file mode 100644 index 0000000000..603afe63ee --- /dev/null +++ b/scripts/qemuimage-tests/toolchain/sudoku-savant | |||
@@ -0,0 +1,31 @@ | |||
1 | #!/bin/bash | ||
2 | # | ||
3 | # sudoku-savant compile Test for toolchain test | ||
4 | # The case extract toolchain tarball into temp folder | ||
5 | # Then compile sudoku-savant with the toolchain environment | ||
6 | # | ||
7 | # Author: Jiajun Xu <jiajun.xu@intel.com> | ||
8 | # | ||
9 | # This file is licensed under the GNU General Public License, | ||
10 | # Version 2. | ||
11 | # | ||
12 | . $COREBASE/scripts/qemuimage-testlib | ||
13 | |||
14 | TIMEOUT=120 | ||
15 | |||
16 | # Extract and test toolchain tarball | ||
17 | Test_Toolchain sudoku-savant ${TIMEOUT} | ||
18 | |||
19 | if [ $? -eq 0 ]; then | ||
20 | Test_Info "sudoku-savant Test PASS" | ||
21 | Test_Print_Result "sudoku-savant" 0 | ||
22 | exit 0 | ||
23 | elif [ $? -eq 1 ]; then | ||
24 | Test_Info "sudoku-savant Test FAIL" | ||
25 | Test_Print_Result "sudoku-savant" 1 | ||
26 | exit 1 | ||
27 | else | ||
28 | Test_Info "Skip sudoku-savant Test due to some configuration problem" | ||
29 | Test_Print_Result "sudoku-savant" 2 | ||
30 | exit 2 | ||
31 | fi | ||