Restructure testjs