Deep copy an_list so that we can pop out items as we please transparently to the user.
Add APITest to automate testing of the ahkab Python interface.