60 likes | 74 Views
TinyOS 1.2. Documentation & Testing. Goal - Stable System. My role: 80/20 Make TinyOS “production quality” Open source version numbering: odd minors development, evens stable. Rules for check-in: Code tested Code documented. Testing - Why.
E N D
TinyOS 1.2 Documentation & Testing
Goal - Stable System • My role: 80/20 • Make TinyOS “production quality” • Open source version numbering: odd minors development, evens stable. • Rules for check-in: • Code tested • Code documented
Testing - Why • Software engineering mantra: if it isn’t tested it doesn’t really work. • Tests: • Contribute to (define?) stability. • Allow refactoring and re-engineering - can throw out what’s stale. • Can document intent in a way code can’t
Testing - How • Framework • QMTest (http://www.codesourcery.com) • Database, process control, text or web, open source. • Every test should encapsulate a problem. • Types of tests: • Component: Encapsulate conditionals (mocks) • Regression: capture existing behavior. (Note: want tests to show changes in behavior also!) • Functional: Application/component behaves as expected under real conditions. • Stress: Run for a long time, under staged adverse conditions. • Statistical: Gather data for later analysis.
Testing - Examples • TinyOS: • Out of resources • Resource conflicts • Proper wirings • Packet loss (regular or irregular) • Edge conditions! • NesC • GCC suite (C correctness) • NesC correctness • Regression testing.
Documentation • Component/function level (NesDoc) • Programmer’s manual • Reference manual • Tutorial • Cookbook • How do I send information to a PC? • How do I enable the radio? • How do I write a new radio?