add basic logic and test