added code and tests for Actions