blob: 9997b964d603ebe7e130b394b4a4085ea8217fbd [file] [log] [blame]
Tests document.visibilityState and the visibilitychange event when entering the backforward cache.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
pageshow - not from cache
PASS document.visibilityState is "visible"
pagehide - entering cache
PASS document.visibilityState is "visible"
PASS visibilityChangeEventCount is 0
visibilitychange - visibilityState: hidden
PASS document.visibilityState is "hidden"
visibilitychange - visibilityState: visible
PASS document.visibilityState is "visible"
pageshow - from cache
PASS document.visibilityState is "visible"
PASS visibilityChangeEventCount is 2
PASS Page did enter and was restored from the page cache
PASS successfullyParsed is true
TEST COMPLETE