An Extensible Fault-Based Predicate Testing Toolset for
Wireless Sensor Network Software Applications

Research & Development

Our testing methodology

The importance of testing sensor network applications cannot be overstressed.

We leverage the notion of test patterns to enable the embedded systems to be testable structurally and statically. We have employed the notion of patterns in detecting context inconsistencies in embedded systems. We use configuration parameters to alter the behaviour of the test patterns. In this way, dynamic compilation of test code can be avoided or minimized. Based on the test patterns, the execution of test cases can be monitored. Among many test pattern proposals, we manage to choose patterns that have minimal memory requirements in this development project.

We choose to use TinyOS, the de facto operating system for WSN applications, as well as its programming language nesC for our project. We expect our toolset to be directly usable by the industry to augment their software development tasks. Hence, the recurrent cost of re-developing the toolset is kept to the minimum.


The following technologies will be adopted:

  • Our novel research results on the extended fault class hierarchy [1] for predicate testing will be adopted as the basis for measuring fault coverage. Our fault hierarchy is more comprehensive than the previous proposal.


    • Since the embedded code in nesC is difficult, the ability to know that a test can fulfil a certain level of fault coverage will definitely help software engineers to plan their testing activities smartly and iteratively.

  • The standardized MC/DC test coverage and our MUMCUT test coverage [2] will be used to measure the condition coverage in predicate testing. The MC/DC (Modified Condition/Decision Coverage) criterion is a de facto standard for many industries such as for automotive devices and airborne systems. MUMCUT criterion is a fault-centric one. We realize these two criteria in the toolset.


    • Software engineers can use conventional testing criteria to assure their programs, or use a fault-proof criterion (i.e., MUMCUT) as the objective to develop test scripts. The value-added fault coverage information provided by the fault class hierarchy will further help software engineers to make decisions on testing their programs.

  • The Unified Modelling Language (UML) will be used for modelling and as the notation for system development and documentation. UML is the de facto standard for software development. We shall also use UML as a part of the user documentation.


    • One one hand, the result of this project is transferable to the potential industry partners, if any.

    • On the other hand, software engineers can learn the toolsets from documentation, without the worry of the unfamiliar notations.

  • The Eclipse Plug-in technology will be adopted so that software engineers would use their favourite development environment (i.e., Eclipse) to develop and test their programs.


    • First, the Plug-in technology allows components to be developed separately and then integrate at run time.

    • Second, this loose couple feature facilitates the extension of existing features of the toolset.

    • Third, the plug-in development leverages the development schedule and the chance for us to further improve the toolset to bring additional advantages to the local industry.

  • Selected test patterns will be implemented.


    • Test patterns facilitate the execution of test cases.

  • Extensible Markup Language (XML) will be used to define fault hierarchy and other important repository data.


    • XML is a popular and powerful standard documentation exchange standard.

  • The agile approach of Unified Software Development Process will be adopted.


    • Since there are sustainable research and experimental trials such as finding and evaluating test pattern implementation to fit for the memory requirements, the approach can save the efforts spent in the Inception phase and the Elaboration phase.

    • The agile approach uses test-driven techniques to test the feasibility of new requirements. It frequently produces small and intermediate prototypes. This is suitable for the exploratory nature of this project to implement a testing toolset for an emergent application domain. We shall construct it through incremental development and integration of individual components.


[1] M. F. Lau and Y. T. Yu, An extended fault class hierarchy for specification-based testing, ACM Transactions on Software Engineering and Methodology 14 (3): 247-276 (2005).

[2] Y. T. Yu and M. F. Lau, A comparison of MC/DC, MUMCUT and several other coverage criteria for logical decisions, Journal of Systems and Software 79 (5):577-590 (2006).

[3] Chang Xu, S.C. Cheung and W.K. Chan, Incremental consistency checking for pervasive contexts, in Proceedings of the 28th International Conference on Software Engineering, pages 292-301, ACM Press, New York, NY, 2006.

[4] Chan Xu and S.C. Cheung, Inconsistency detection and resolution for context-aware middleware support, in Proceedings of the Joint 10th European Software Engineering Conference and 13th ACM SIGSOFT Symposium on the Foundation of Software Engineering, pages 336-345, ACM Press, New York, NY, 2006.

[5] T.H. Tse, F.C.M. Lau, W.K. Chan, P.C.K. Liu, and C.K.F. Luk, Testing of object-oriented industrial software without precise oracles or results, Communications of the ACM 58 (8) (2007).

[6] H.Y. Chen, T.H. Tse, and T.Y. Chen, TACCLE: a methodology for object-oriented software testing at the class and cluster levels, ACM Transactions on Software Engineering and Methodology 10 (1): 56-109 (2001).

[7] W.K. Chan, T.Y. Chen, S.C. Cheung, T.H. Tse and Z.Y. Zhang, Towards the testing of power-aware software applications for wireless sensor networks, Proceedings of the 12th International Conference on Reliable Software Technologies (Ada-Europe 2007), 25-29 June 2007, Geneva, Switzerland.

[8] Heng Lu, W.K. Chan and T.H. Tse, Testing context-aware middleware-centric programs: a data flow approach and an RFID-based experimentation, in Proceedings of the 14th ACM SIGSOFT Symposium on Foundations of Software Engineering (SIGSOFT 2006/FSE-14), page 242-252, ACM Press, New York, NY, 2006.