From 0a03c4d2377191b8c2f919cfcd126b09eab6a54d Mon Sep 17 00:00:00 2001 From: nvt-se Date: Thu, 18 Sep 2008 10:36:48 +0000 Subject: [PATCH] added the Coffee test to Cooja. --- tools/cooja/contiki_tests/sky_coffee.csc | 40 +++++++++++++++++++++++ tools/cooja/contiki_tests/sky_coffee.info | 1 + tools/cooja/contiki_tests/sky_coffee.js | 10 ++++++ 3 files changed, 51 insertions(+) create mode 100644 tools/cooja/contiki_tests/sky_coffee.csc create mode 100644 tools/cooja/contiki_tests/sky_coffee.info create mode 100644 tools/cooja/contiki_tests/sky_coffee.js diff --git a/tools/cooja/contiki_tests/sky_coffee.csc b/tools/cooja/contiki_tests/sky_coffee.csc new file mode 100644 index 000000000..af0d5314b --- /dev/null +++ b/tools/cooja/contiki_tests/sky_coffee.csc @@ -0,0 +1,40 @@ + + + + test + 0 + 1 + 123456 + 1 + 0 + + se.sics.cooja.radiomediums.UDGM + 50.0 + 100.0 + 1.0 + 1.0 + + + se.sics.cooja.mspmote.SkyMoteType + sky1 + Sky Mote Type #1 + /home/nvt/contiki-2.x-clean/examples/sky/test-coffee.c + make test-coffee.firmware TARGET=sky + + + se.sics.cooja.mspmote.SkyMote + sky1 + + se.sics.cooja.interfaces.Position + 97.11078411573273 + 56.790978919276014 + 0.0 + + + se.sics.cooja.mspmote.interfaces.MspMoteID + 1 + + + + + diff --git a/tools/cooja/contiki_tests/sky_coffee.info b/tools/cooja/contiki_tests/sky_coffee.info new file mode 100644 index 000000000..3d78c8d76 --- /dev/null +++ b/tools/cooja/contiki_tests/sky_coffee.info @@ -0,0 +1 @@ +Single Sky node. Coffee consistency test. \ No newline at end of file diff --git a/tools/cooja/contiki_tests/sky_coffee.js b/tools/cooja/contiki_tests/sky_coffee.js new file mode 100644 index 000000000..29003a799 --- /dev/null +++ b/tools/cooja/contiki_tests/sky_coffee.js @@ -0,0 +1,10 @@ +/* Script is called once for every node log output. */ +/* Input variables: Mote mote, int id, String msg. */ + +if (msg.startsWith('Coffee consistency test: 0')) { + log.log('TEST OK'); + mote.getSimulation().getGUI().doQuit(false); /* Quit simulator (to end test run)*/ +} else if (msg.startsWith('Coffee consistency test')) { + log.log('TEST FAILED'); + mote.getSimulation().getGUI().doQuit(false); /* Quit simulator (to end test run)*/ +}