adds basic test, fixes some namespace bugs