1. Make tests part javascript where applicable