[master] Tests for "when"