df

Dependencies:   mbed

Fork of APP1 by Team APP

Revision:
13:bb9669053eb3
Parent:
12:1c341b119b23
Child:
15:b38d9d210e32
--- a/TestUtility.cpp	Sun Jan 15 19:46:10 2017 +0000
+++ b/TestUtility.cpp	Mon Jan 16 00:06:45 2017 +0000
@@ -12,6 +12,7 @@
         test_wrap_angle();
         test_update_bit();
         test_update_bit_for_values_greater_than_one_byte();
+        test_update_bits();
     }
     
     void test_is_almost_equal()
@@ -58,4 +59,10 @@
         assert(0x7FFF == update_bit(0xFFFF, 15, 0));
         assert(0x7FFFFFFF == update_bit(0xFFFFFFFF, 31, 0));
     }
+    
+    void test_update_bits()
+    {
+        assert(0x0F == update_bits(0x00, 0, 3, 0x0F));
+        assert(0x1E == update_bits(0x00, 1, 4, 0x0F));
+    }
 }
\ No newline at end of file