Added a bit testing code