[test] make sure to listen before dispatching