Commit 1b97ec54 authored by Alex Saveau's avatar Alex Saveau
Browse files

Update chapter2-exercise-zoom-tests.md

parent 36ec27af
......@@ -49,14 +49,14 @@ Calling `zoomout` should make the font size 8, and the gaps between words should
Calling `zoomin` should restore the default output.
>>> this_browser.zoomin({})
create_text: x=12 y=18 text=a font=Font size=16 weight=None slant=None style=None anchor=None
create_text: x=24 y=18 text=b font=Font size=16 weight=None slant=None style=None anchor=None
create_text: x=13 y=18 text=a font=Font size=16 weight=None slant=None style=None anchor=None
create_text: x=26 y=18 text=b font=Font size=16 weight=None slant=None style=None anchor=None
Calling `zoomin` again should make the font size 32, make the gaps between letter huge.
>>> this_browser.zoomin({})
create_text: x=24 y=36 text=a font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=48 y=36 text=b font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=36 text=a font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=52 y=36 text=b font=Font size=32 weight=None slant=None style=None anchor=None
Scrolling while zoomed
---------------------
......@@ -72,22 +72,22 @@ Let's mock a URL and load it:
>>> test.socket.respond_200(url=url,
... body="abcd")
>>> this_browser.load(url)
create_text: x=24 y=36 text=a font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=24 y=72 text=b font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=24 y=108 text=c font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=24 y=144 text=d font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=36 text=a font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=72 text=b font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=108 text=c font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=144 text=d font=Font size=32 weight=None slant=None style=None anchor=None
Scroll down
>>> this_browser.scrolldown({})
create_text: x=24 y=-2 text=a font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=24 y=34 text=b font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=24 y=70 text=c font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=24 y=106 text=d font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=-2 text=a font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=34 text=b font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=70 text=c font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=106 text=d font=Font size=32 weight=None slant=None style=None anchor=None
Again
>>> this_browser.scrolldown({})
create_text: x=24 y=-4 text=b font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=24 y=32 text=c font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=24 y=68 text=d font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=-4 text=b font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=32 text=c font=Font size=32 weight=None slant=None style=None anchor=None
create_text: x=26 y=68 text=d font=Font size=32 weight=None slant=None style=None anchor=None
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment