# Stores pass (S008): history, bookmarks (add, folder, bar, Netscape HTML export/import), downloads page, and that all
# of it is still there after a restart. Offline. Part 1 (hidden):
#   python3 -m http.server 8768 --bind 127.0.0.1 --directory tests/smoke/pages &
#   python3 tests/smoke/net/server.py &
#   tools/smoke.sh tests/smoke/stores-lists.txt <outdir>
# Part 2: SMOKE_HOME=<outdir>/home tools/smoke.sh tests/smoke/stores-lists-restart.txt <outdir2>
wait 3
resize 1280 900
open http://127.0.0.1:8768/hello.html
waitload
open http://127.0.0.1:8768/site.html
waitload
status visits
expect /history > 1
page nacre://history
wait 1
shot history
# Bookmark the page, make a folder, show the bar.
open http://127.0.0.1:8768/site.html
waitload
cmd bookmark
wait 1
flyout none
bookmarks folder Work
set /ui/bookmarks_bar "always"
wait 1
status marked
expect /bookmarks 1
expect /bookmark_folders 1
shot bar
# Export, then import a file in another browser's layout: 1 on the bar + 2 in a folder, then again adds nothing.
bookmarks export @HOME@/bookmarks-export.html
bookmarks import @PAGESDIR@/chrome-bookmarks.html
bookmarks import @PAGESDIR@/chrome-bookmarks.html
status imported
expect /bookmarks 4
page nacre://bookmarks
wait 1
shot bookmarks
# Downloads: one finished file listed on the page.
cmd download http://127.0.0.1:8766/file.zip
wait 4
status download
expect /downloads/0/state "Done"
page nacre://downloads
wait 1
shot downloads
status done
quit
