Updating to properly work with require
Adding tests