added api tests -- closes #28