Flesh out test, fix bug.