From bd2c039dc64e4e3644f7ae3d814fb8730097aa86 Mon Sep 17 00:00:00 2001 From: adamdunkels Date: Tue, 4 Nov 2008 15:17:31 +0000 Subject: [PATCH] Test that checks if the Contiki shell compiles and runs on the Tmote Sky --- .../sky_shell_compilation_test.csc | 70 +++++++++++++++++++ .../sky_shell_compilation_test.info | 1 + .../sky_shell_compilation_test.js | 13 ++++ 3 files changed, 84 insertions(+) create mode 100644 tools/cooja/contiki_tests/sky_shell_compilation_test.csc create mode 100644 tools/cooja/contiki_tests/sky_shell_compilation_test.info create mode 100644 tools/cooja/contiki_tests/sky_shell_compilation_test.js diff --git a/tools/cooja/contiki_tests/sky_shell_compilation_test.csc b/tools/cooja/contiki_tests/sky_shell_compilation_test.csc new file mode 100644 index 000000000..27a52f456 --- /dev/null +++ b/tools/cooja/contiki_tests/sky_shell_compilation_test.csc @@ -0,0 +1,70 @@ + + + + My simulation + 0 + 1 + 123456 + 1000 + + se.sics.cooja.radiomediums.UDGM + 50.0 + 100.0 + 1.0 + 1.0 + + + se.sics.cooja.mspmote.SkyMoteType + sky1 + Sky Mote Type #1 + ../../../examples/sky-shell/sky-shell.c + make sky-shell.sky TARGET=sky + + + se.sics.cooja.mspmote.SkyMote + sky1 + + se.sics.cooja.interfaces.Position + 62.86427076032819 + 38.98246035522194 + 0.0 + + + se.sics.cooja.mspmote.interfaces.MspMoteID + 1 + + + + + se.sics.cooja.plugins.SimControl + 302 + 1 + 187 + 0 + 0 + false + + + se.sics.cooja.plugins.VisState + 300 + 3 + 300 + 390 + 0 + false + + + se.sics.cooja.plugins.LogListener + + + 256 + + 690 + 2 + 190 + 0 + 457 + false + + + diff --git a/tools/cooja/contiki_tests/sky_shell_compilation_test.info b/tools/cooja/contiki_tests/sky_shell_compilation_test.info new file mode 100644 index 000000000..7554f5d73 --- /dev/null +++ b/tools/cooja/contiki_tests/sky_shell_compilation_test.info @@ -0,0 +1 @@ +This test tries to compile and run the Contiki shell on the Tmote Sky. The test succeeds when contiki-sky-main.c prints out the word "Contiki". diff --git a/tools/cooja/contiki_tests/sky_shell_compilation_test.js b/tools/cooja/contiki_tests/sky_shell_compilation_test.js new file mode 100644 index 000000000..e9c1a1da4 --- /dev/null +++ b/tools/cooja/contiki_tests/sky_shell_compilation_test.js @@ -0,0 +1,13 @@ +/* Script is called once for every node log output. */ +/* Input variables: Mote mote, int id, String msg. */ + +/* Contiki test script example */ +if (msg.startsWith('Contiki')) { + log.log('TEST OK\n'); /* Report test success */ + + /* To increase test run speed, close the simulator when done */ + mote.getSimulation().getGUI().doQuit(false); /* Quit simulator (to end test run)*/ +} else { + log.log('TEST FAIL\n'); /* Report test failure */ + mote.getSimulation().getGUI().doQuit(false); /* Quit simulator (to end test run)*/ +}