While working on this PR, I introduced a bug where shadow images for
unmapped windows aren't properly recreated after unredirect/redirect.
The shadow image is freed during unredirect, OTOH redirect only set
IMAGE_STALE flags for mapped window, thus the shadow images for unmapped
windows will be missing.
This bug is already fixed in the previous commit. But the testcase is
good to keep nonetheless.
Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>