Added sitting logic and tests