fixed test, added create factory method, improved autoloading