Started test suite and improved commonJS module definition