fix wait behavior and add test to cover it
Release 1.1.3