Copy over functions from directive to service
add continuous tests