testing.py: new file, for compatibility with numpy