Corrected errors in testing.py
Added draft to_ndarray