bdd: Remove trailing dots.
This commit is contained in:
parent
f56e7b1220
commit
6f1474be71
@ -47,7 +47,7 @@ Feature: Going back and forward.
|
||||
Given I open data/backforward/1.txt
|
||||
When I run :tab-only
|
||||
And I run :back -t
|
||||
Then the error "At beginning of history." should be shown.
|
||||
Then the error "At beginning of history." should be shown
|
||||
Then the session should look like:
|
||||
windows:
|
||||
- tabs:
|
||||
@ -97,8 +97,8 @@ Feature: Going back and forward.
|
||||
When I run :back with count 99999999999
|
||||
# Make sure it doesn't hang
|
||||
And I run :message-info "Still alive!"
|
||||
Then the error "At beginning of history." should be shown.
|
||||
And the message "Still alive!" should be shown.
|
||||
Then the error "At beginning of history." should be shown
|
||||
And the message "Still alive!" should be shown
|
||||
|
||||
Scenario: Going back in a new window
|
||||
Given I have a fresh instance
|
||||
@ -126,9 +126,9 @@ Feature: Going back and forward.
|
||||
Scenario: Going back without history
|
||||
Given I open data/backforward/1.txt
|
||||
When I run :back
|
||||
Then the error "At beginning of history." should be shown.
|
||||
Then the error "At beginning of history." should be shown
|
||||
|
||||
Scenario: Going forward without history
|
||||
Given I open data/backforward/1.txt
|
||||
When I run :forward
|
||||
Then the error "At end of history." should be shown.
|
||||
Then the error "At end of history." should be shown
|
||||
|
@ -191,7 +191,7 @@ def list_of_requests_unordered(httpbin, pages):
|
||||
|
||||
|
||||
@bdd.then(bdd.parsers.re(r'the (?P<category>error|message|warning) '
|
||||
r'"(?P<message>.*)" should be shown.'))
|
||||
r'"(?P<message>.*)" should be shown'))
|
||||
def expect_message(quteproc, httpbin, category, message):
|
||||
"""Expect the given message in the qutebrowser log."""
|
||||
category_to_loglevel = {
|
||||
|
@ -37,24 +37,24 @@ Feature: Downloading things from a website.
|
||||
When I open data/downloads/download.bin
|
||||
And I wait until the download is finished
|
||||
And I run :download-retry
|
||||
Then the error "No failed downloads!" should be shown.
|
||||
Then the error "No failed downloads!" should be shown
|
||||
|
||||
Scenario: Retrying with no downloads
|
||||
When I run :download-retry
|
||||
Then the error "No failed downloads!" should be shown.
|
||||
Then the error "No failed downloads!" should be shown
|
||||
|
||||
Scenario: :download with deprecated dest-old argument
|
||||
When I run :download http://localhost:(port)/ deprecated-argument
|
||||
Then the warning ":download [url] [dest] is deprecated - use download --dest [dest] [url]" should be shown.
|
||||
Then the warning ":download [url] [dest] is deprecated - use download --dest [dest] [url]" should be shown
|
||||
|
||||
Scenario: Two destinations given
|
||||
When I run :download --dest destination2 http://localhost:(port)/ destination1
|
||||
Then the warning ":download [url] [dest] is deprecated - use download --dest [dest] [url]" should be shown.
|
||||
And the error "Can't give two destinations for the download." should be shown.
|
||||
Then the warning ":download [url] [dest] is deprecated - use download --dest [dest] [url]" should be shown
|
||||
And the error "Can't give two destinations for the download." should be shown
|
||||
|
||||
Scenario: :download --mhtml with an URL given
|
||||
When I run :download --mhtml http://foobar/
|
||||
Then the error "Can only download the current page as mhtml." should be shown.
|
||||
Then the error "Can only download the current page as mhtml." should be shown
|
||||
|
||||
Scenario: Downloading as mhtml is available
|
||||
When I open html
|
||||
|
@ -11,10 +11,10 @@ Feature: Using hints
|
||||
|
||||
Scenario: Using :follow-hint outside of hint mode (issue 1105)
|
||||
When I run :follow-hint
|
||||
Then the error "follow-hint: This command is only allowed in hint mode." should be shown.
|
||||
Then the error "follow-hint: This command is only allowed in hint mode." should be shown
|
||||
|
||||
Scenario: Using :follow-hint with an invalid index.
|
||||
When I open data/hints/link.html
|
||||
And I run :hint links normal
|
||||
And I run :follow-hint xyz
|
||||
Then the error "No hint xyz!" should be shown.
|
||||
Then the error "No hint xyz!" should be shown
|
||||
|
@ -8,28 +8,28 @@ Feature: Keyboard input
|
||||
Scenario: Binding a keychain
|
||||
When I run :bind test1 message-info test1
|
||||
And I press the keys "test1"
|
||||
Then the message "test1" should be shown.
|
||||
Then the message "test1" should be shown
|
||||
|
||||
Scenario: Binding an invalid command
|
||||
When I run :bind test2 abcd
|
||||
Then the error "Invalid command 'abcd'!" should be shown.
|
||||
Then the error "Invalid command 'abcd'!" should be shown
|
||||
|
||||
Scenario: Binding with invalid mode.
|
||||
When I run :bind --mode abcd test3 message-info test3
|
||||
Then the error "Invalid mode abcd!" should be shown.
|
||||
Then the error "Invalid mode abcd!" should be shown
|
||||
|
||||
Scenario: Double-binding a key
|
||||
When I run :bind test4 message-info test4
|
||||
And I run :bind test4 message-info test4-2
|
||||
And I press the keys "test4"
|
||||
Then the error "Duplicate keychain test4 - use --force to override!" should be shown.
|
||||
And the message "test4" should be shown.
|
||||
Then the error "Duplicate keychain test4 - use --force to override!" should be shown
|
||||
And the message "test4" should be shown
|
||||
|
||||
Scenario: Double-binding with --force
|
||||
When I run :bind test5 message-info test5
|
||||
And I run :bind --force test5 message-info test5-2
|
||||
And I press the keys "test5"
|
||||
Then the message "test5-2" should be shown.
|
||||
Then the message "test5-2" should be shown
|
||||
|
||||
# :unbind
|
||||
|
||||
@ -41,11 +41,11 @@ Feature: Keyboard input
|
||||
|
||||
Scenario: Unbinding with invalid mode.
|
||||
When I run :unbind test7 abcd
|
||||
Then the error "Invalid mode abcd!" should be shown.
|
||||
Then the error "Invalid mode abcd!" should be shown
|
||||
|
||||
Scenario: Unbinding with invalid keychain.
|
||||
When I run :unbind test8
|
||||
Then the error "Can't find binding 'test8' in section 'normal'!" should be shown.
|
||||
Then the error "Can't find binding 'test8' in section 'normal'!" should be shown
|
||||
|
||||
Scenario: Unbinding a built-in binding
|
||||
When I run :unbind o
|
||||
@ -61,7 +61,7 @@ Feature: Keyboard input
|
||||
And I press the keys "fo"
|
||||
And I run :clear-keychain
|
||||
And I press the keys "bar"
|
||||
Then the message "test9-2" should be shown.
|
||||
Then the message "test9-2" should be shown
|
||||
|
||||
# input -> forward-unbound-keys
|
||||
|
||||
@ -104,7 +104,7 @@ Feature: Keyboard input
|
||||
|
||||
Scenario: :fake-key with an unparsable key
|
||||
When I run :fake-key <blub>
|
||||
Then the error "Could not parse 'blub': Got unknown key." should be shown.
|
||||
Then the error "Could not parse 'blub': Got unknown key." should be shown
|
||||
|
||||
Scenario: :fake-key sending key to the website
|
||||
When I set general -> log-javascript-console to true
|
||||
@ -122,7 +122,7 @@ Feature: Keyboard input
|
||||
And I run :fake-key x
|
||||
And I run :inspector
|
||||
And I wait for "Focus object changed: *" in the log
|
||||
Then the error "No focused webview!" should be shown.
|
||||
Then the error "No focused webview!" should be shown
|
||||
|
||||
Scenario: :fake-key sending special key to the website
|
||||
When I set general -> log-javascript-console to true
|
||||
|
@ -5,47 +5,47 @@ Feature: Various utility commands.
|
||||
Scenario: :set-cmd-text and :command-accept
|
||||
When I run :set-cmd-text :message-info "Hello World"
|
||||
And I run :command-accept
|
||||
Then the message "Hello World" should be shown.
|
||||
Then the message "Hello World" should be shown
|
||||
|
||||
Scenario: :set-cmd-text with two commands
|
||||
When I run :set-cmd-text :message-info test ;; message-error error
|
||||
And I run :command-accept
|
||||
Then the message "test" should be shown.
|
||||
And the error "error" should be shown.
|
||||
Then the message "test" should be shown
|
||||
And the error "error" should be shown
|
||||
|
||||
Scenario: :set-cmd-text with URL replacement
|
||||
When I open data/hello.txt
|
||||
When I run :set-cmd-text :message-info >{url}<
|
||||
And I run :command-accept
|
||||
Then the message ">http://localhost:*/hello.txt<" should be shown.
|
||||
Then the message ">http://localhost:*/hello.txt<" should be shown
|
||||
|
||||
Scenario: :set-cmd-text with -s and -a
|
||||
When I run :set-cmd-text -s :message-info "foo
|
||||
And I run :set-cmd-text -a bar"
|
||||
And I run :command-accept
|
||||
Then the message "foo bar" should be shown.
|
||||
Then the message "foo bar" should be shown
|
||||
|
||||
Scenario: :set-cmd-text with -a but without text
|
||||
When I run :set-cmd-text -a foo
|
||||
Then the error "No current text!" should be shown.
|
||||
Then the error "No current text!" should be shown
|
||||
|
||||
Scenario: :set-cmd-text with invalid command
|
||||
When I run :set-cmd-text foo
|
||||
Then the error "Invalid command text 'foo'." should be shown.
|
||||
Then the error "Invalid command text 'foo'." should be shown
|
||||
|
||||
## :message-*
|
||||
|
||||
Scenario: :message-error
|
||||
When I run :message-error "Hello World"
|
||||
Then the error "Hello World" should be shown.
|
||||
Then the error "Hello World" should be shown
|
||||
|
||||
Scenario: :message-info
|
||||
When I run :message-info "Hello World"
|
||||
Then the message "Hello World" should be shown.
|
||||
Then the message "Hello World" should be shown
|
||||
|
||||
Scenario: :message-warning
|
||||
When I run :message-warning "Hello World"
|
||||
Then the warning "Hello World" should be shown.
|
||||
Then the warning "Hello World" should be shown
|
||||
|
||||
## :jseval
|
||||
|
||||
@ -53,12 +53,12 @@ Feature: Various utility commands.
|
||||
When I set general -> log-javascript-console to true
|
||||
And I run :jseval console.log("Hello from JS!");
|
||||
And I wait for "[:0] Hello from JS!" in the log
|
||||
Then the message "No output or error" should be shown.
|
||||
Then the message "No output or error" should be shown
|
||||
|
||||
Scenario: :jseval without logging
|
||||
When I set general -> log-javascript-console to false
|
||||
And I run :jseval console.log("Hello from JS!");
|
||||
Then the message "No output or error" should be shown.
|
||||
Then the message "No output or error" should be shown
|
||||
And "[:0] Hello from JS!" should not be logged
|
||||
|
||||
Scenario: :jseval with --quiet
|
||||
@ -69,11 +69,11 @@ Feature: Various utility commands.
|
||||
|
||||
Scenario: :jseval with a value
|
||||
When I run :jseval "foo"
|
||||
Then the message "foo" should be shown.
|
||||
Then the message "foo" should be shown
|
||||
|
||||
Scenario: :jseval with a long, truncated value
|
||||
When I run :jseval Array(5002).join("x")
|
||||
Then the message "x* [...trimmed...]" should be shown.
|
||||
Then the message "x* [...trimmed...]" should be shown
|
||||
|
||||
# :debug-webaction
|
||||
|
||||
@ -94,19 +94,19 @@ Feature: Various utility commands.
|
||||
Scenario: :debug-webaction with invalid value
|
||||
When I open data/hello.txt
|
||||
And I run :debug-webaction blah
|
||||
Then the error "blah is not a valid web action!" should be shown.
|
||||
Then the error "blah is not a valid web action!" should be shown
|
||||
|
||||
Scenario: :debug-webaction with non-webaction member
|
||||
When I open data/hello.txt
|
||||
And I run :debug-webaction PermissionUnknown
|
||||
Then the error "PermissionUnknown is not a valid web action!" should be shown.
|
||||
Then the error "PermissionUnknown is not a valid web action!" should be shown
|
||||
|
||||
# :inspect
|
||||
|
||||
Scenario: Inspector without developer extras
|
||||
When I set general -> developer-extras to false
|
||||
And I run :inspector
|
||||
Then the error "Please enable developer-extras before using the webinspector!" should be shown.
|
||||
Then the error "Please enable developer-extras before using the webinspector!" should be shown
|
||||
|
||||
@not_xvfb @posix
|
||||
Scenario: Inspector smoke test
|
||||
@ -168,7 +168,7 @@ Feature: Various utility commands.
|
||||
When I open data/hello.txt
|
||||
And I run :view-source
|
||||
And I run :view-source
|
||||
Then the error "Already viewing source!" should be shown.
|
||||
Then the error "Already viewing source!" should be shown
|
||||
|
||||
# :debug-console
|
||||
|
||||
|
@ -2,7 +2,7 @@ Feature: Using :navigate
|
||||
|
||||
Scenario: :navigate with invalid argument
|
||||
When I run :navigate foo
|
||||
Then the error "Invalid value foo." should be shown.
|
||||
Then the error "Invalid value foo." should be shown
|
||||
|
||||
# up
|
||||
|
||||
@ -14,7 +14,7 @@ Feature: Using :navigate
|
||||
Scenario: Navigating up with root directory
|
||||
When I open /
|
||||
And I run :navigate up
|
||||
Then the error "Can't go up!" should be shown.
|
||||
Then the error "Can't go up!" should be shown
|
||||
|
||||
# prev/next
|
||||
|
||||
@ -31,12 +31,12 @@ Feature: Using :navigate
|
||||
Scenario: Navigating to previous page without links
|
||||
When I open data/numbers/1.txt
|
||||
And I run :navigate prev
|
||||
Then the error "No prev links found!" should be shown.
|
||||
Then the error "No prev links found!" should be shown
|
||||
|
||||
Scenario: Navigating to next page without links
|
||||
When I open data/numbers/1.txt
|
||||
And I run :navigate next
|
||||
Then the error "No forward links found!" should be shown.
|
||||
Then the error "No forward links found!" should be shown
|
||||
|
||||
# increment/decrement
|
||||
|
||||
@ -53,15 +53,15 @@ Feature: Using :navigate
|
||||
Scenario: Decrementing with no number in URL
|
||||
When I open data/navigate
|
||||
And I run :navigate decrement
|
||||
Then the error "No number found in URL!" should be shown.
|
||||
Then the error "No number found in URL!" should be shown
|
||||
|
||||
Scenario: Incrementing with no number in URL
|
||||
When I open data/navigate
|
||||
And I run :navigate increment
|
||||
Then the error "No number found in URL!" should be shown.
|
||||
Then the error "No number found in URL!" should be shown
|
||||
|
||||
Scenario: Setting url-incdec-segments
|
||||
When I set general -> url-incdec-segments to anchor
|
||||
And I open data/numbers/1.txt
|
||||
And I run :navigate increment
|
||||
Then the error "No number found in URL!" should be shown.
|
||||
Then the error "No number found in URL!" should be shown
|
||||
|
@ -16,7 +16,7 @@ Feature: Opening pages
|
||||
|
||||
Scenario: :open without URL and no -t/-b/-w
|
||||
When I run :open
|
||||
Then the error "No URL given, but -t/-b/-w is not set!" should be shown.
|
||||
Then the error "No URL given, but -t/-b/-w is not set!" should be shown
|
||||
|
||||
Scenario: :open without URL and -t
|
||||
When I set general -> default-page to http://localhost:(port)/data/numbers/2.txt
|
||||
@ -26,11 +26,11 @@ Feature: Opening pages
|
||||
Scenario: :open with invalid URL
|
||||
When I set general -> auto-search to false
|
||||
And I run :open foo!
|
||||
Then the error "Invalid URL" should be shown.
|
||||
Then the error "Invalid URL" should be shown
|
||||
|
||||
Scenario: :open with -t and -b
|
||||
When I run :open -t -b foo.bar
|
||||
Then the error "Only one of -t/-b/-w can be given!" should be shown.
|
||||
Then the error "Only one of -t/-b/-w can be given!" should be shown
|
||||
|
||||
Scenario: Searching with :open
|
||||
When I set general -> auto-search to naive
|
||||
|
@ -9,37 +9,37 @@ Feature: Scrolling
|
||||
|
||||
Scenario: Scrolling pixel-wise vertically
|
||||
When I run :scroll-px 0 10
|
||||
Then the page should be scrolled vertically.
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: Scrolling pixel-wise horizontally
|
||||
When I run :scroll-px 10 0
|
||||
Then the page should be scrolled horizontally.
|
||||
Then the page should be scrolled horizontally
|
||||
|
||||
Scenario: Scrolling down and up
|
||||
When I run :scroll-px 10 0
|
||||
And I run :scroll-px -10 0
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling right and left
|
||||
When I run :scroll-px 0 10
|
||||
And I run :scroll-px 0 -10
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling down and up with count
|
||||
When I run :scroll-px 0 10 with count 2
|
||||
When I run :scroll-px 0 -10
|
||||
When I run :scroll-px 0 -10
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling left and right with count
|
||||
When I run :scroll-px 10 0 with count 2
|
||||
When I run :scroll-px -10 0
|
||||
When I run :scroll-px -10 0
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: :scroll-px with a very big value
|
||||
When I run :scroll-px 99999999999 0
|
||||
Then the error "Numeric argument is too large for internal int representation." should be shown.
|
||||
Then the error "Numeric argument is too large for internal int representation." should be shown
|
||||
|
||||
Scenario: :scroll-px on a page without scrolling
|
||||
When I open data/hello.txt
|
||||
@ -49,88 +49,88 @@ Feature: Scrolling
|
||||
Scenario: :scroll-px with floats
|
||||
# This used to be allowed, but doesn't make much sense.
|
||||
When I run :scroll-px 2.5 2.5
|
||||
Then the error "scroll-px: Argument dx: invalid int value: '2.5'" should be shown.
|
||||
And the page should not be scrolled.
|
||||
Then the error "scroll-px: Argument dx: invalid int value: '2.5'" should be shown
|
||||
And the page should not be scrolled
|
||||
|
||||
## :scroll
|
||||
|
||||
Scenario: Scrolling down
|
||||
When I run :scroll down
|
||||
Then the page should be scrolled vertically.
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: Scrolling down and up
|
||||
When I run :scroll down
|
||||
And I run :scroll up
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling right
|
||||
When I run :scroll right
|
||||
Then the page should be scrolled horizontally.
|
||||
Then the page should be scrolled horizontally
|
||||
|
||||
Scenario: Scrolling right and left
|
||||
When I run :scroll right
|
||||
And I run :scroll left
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling with page down
|
||||
When I run :scroll page-down
|
||||
Then the page should be scrolled vertically.
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: Scrolling with page down and page up
|
||||
When I run :scroll page-down
|
||||
And I run :scroll page-up
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling to bottom
|
||||
When I run :scroll bottom
|
||||
Then the page should be scrolled vertically.
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: Scrolling to bottom and to top
|
||||
When I run :scroll bottom
|
||||
And I run :scroll top
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: :scroll with invalid argument
|
||||
When I run :scroll foobar
|
||||
Then the error "Invalid value 'foobar' for direction - expected one of: bottom, down, left, page-down, page-up, right, top, up" should be shown.
|
||||
And the page should not be scrolled.
|
||||
Then the error "Invalid value 'foobar' for direction - expected one of: bottom, down, left, page-down, page-up, right, top, up" should be shown
|
||||
And the page should not be scrolled
|
||||
|
||||
Scenario: :scroll with deprecated pixel argument
|
||||
When I run :scroll 0 10
|
||||
Then the warning ":scroll with dx/dy arguments is deprecated - use :scroll-px instead!" should be shown.
|
||||
Then the page should be scrolled vertically.
|
||||
Then the warning ":scroll with dx/dy arguments is deprecated - use :scroll-px instead!" should be shown
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: :scroll with deprecated pixel argument (float)
|
||||
When I run :scroll 2.5 2.5
|
||||
Then the error "scroll: Argument dy: invalid int value: '2.5'" should be shown.
|
||||
And the page should not be scrolled.
|
||||
Then the error "scroll: Argument dy: invalid int value: '2.5'" should be shown
|
||||
And the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling down and up with count
|
||||
When I run :scroll down with count 2
|
||||
And I run :scroll up
|
||||
And I run :scroll up
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling right
|
||||
When I run :scroll right
|
||||
Then the page should be scrolled horizontally.
|
||||
Then the page should be scrolled horizontally
|
||||
|
||||
Scenario: Scrolling right and left
|
||||
When I run :scroll right
|
||||
And I run :scroll left
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling right and left with count
|
||||
When I run :scroll right with count 2
|
||||
And I run :scroll left
|
||||
And I run :scroll left
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling down with a very big count
|
||||
When I run :scroll down with count 99999999999
|
||||
# Make sure it doesn't hang
|
||||
And I run :message-info "Still alive!"
|
||||
Then the message "Still alive!" should be shown.
|
||||
Then the message "Still alive!" should be shown
|
||||
|
||||
Scenario: :scroll on a page without scrolling
|
||||
When I open data/hello.txt
|
||||
@ -141,55 +141,55 @@ Feature: Scrolling
|
||||
|
||||
Scenario: Scrolling to bottom with :scroll-perc
|
||||
When I run :scroll-perc 100
|
||||
Then the page should be scrolled vertically.
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: Scrolling to bottom and to top with :scroll-perc
|
||||
When I run :scroll-perc 100
|
||||
And I run :scroll-perc 0
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling to middle with :scroll-perc
|
||||
When I run :scroll-perc 50
|
||||
Then the page should be scrolled vertically.
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: Scrolling to middle with :scroll-perc (float)
|
||||
When I run :scroll-perc 50.5
|
||||
Then the page should be scrolled vertically.
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: Scrolling to middle and to top with :scroll-perc
|
||||
When I run :scroll-perc 50
|
||||
And I run :scroll-perc 0
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling to right with :scroll-perc
|
||||
When I run :scroll-perc --horizontal 100
|
||||
Then the page should be scrolled horizontally.
|
||||
Then the page should be scrolled horizontally
|
||||
|
||||
Scenario: Scrolling to right and to left with :scroll-perc
|
||||
When I run :scroll-perc --horizontal 100
|
||||
And I run :scroll-perc --horizontal 0
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling to middle (horizontally) with :scroll-perc
|
||||
When I run :scroll-perc --horizontal 50
|
||||
Then the page should be scrolled horizontally.
|
||||
Then the page should be scrolled horizontally
|
||||
|
||||
Scenario: Scrolling to middle and to left with :scroll-perc
|
||||
When I run :scroll-perc --horizontal 50
|
||||
And I run :scroll-perc --horizontal 0
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: :scroll-perc without argument
|
||||
When I run :scroll-perc
|
||||
Then the page should be scrolled vertically.
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: :scroll-perc without argument and --horizontal
|
||||
When I run :scroll-perc --horizontal
|
||||
Then the page should be scrolled horizontally.
|
||||
Then the page should be scrolled horizontally
|
||||
|
||||
Scenario: :scroll-perc with count
|
||||
When I run :scroll-perc with count 50
|
||||
Then the page should be scrolled vertically.
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: :scroll-perc with a very big value
|
||||
When I run :scroll-perc 99999999999
|
||||
@ -204,35 +204,35 @@ Feature: Scrolling
|
||||
|
||||
Scenario: Scrolling down with :scroll-page
|
||||
When I run :scroll-page 0 1
|
||||
Then the page should be scrolled vertically.
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: Scrolling down with :scroll-page (float)
|
||||
When I run :scroll-page 0 1.5
|
||||
Then the page should be scrolled vertically.
|
||||
Then the page should be scrolled vertically
|
||||
|
||||
Scenario: Scrolling down and up with :scroll-page
|
||||
When I run :scroll-page 0 1
|
||||
And I run :scroll-page 0 -1
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling right with :scroll-page
|
||||
When I run :scroll-page 1 0
|
||||
Then the page should be scrolled horizontally.
|
||||
Then the page should be scrolled horizontally
|
||||
|
||||
Scenario: Scrolling right with :scroll-page (float)
|
||||
When I run :scroll-page 1.5 0
|
||||
Then the page should be scrolled horizontally.
|
||||
Then the page should be scrolled horizontally
|
||||
|
||||
Scenario: Scrolling right and left with :scroll-page
|
||||
When I run :scroll-page 1 0
|
||||
And I run :scroll-page -1 0
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: Scrolling right and left with :scroll-page and count
|
||||
When I run :scroll-page 1 0 with count 2
|
||||
And I run :scroll-page -1 0
|
||||
And I run :scroll-page -1 0
|
||||
Then the page should not be scrolled.
|
||||
Then the page should not be scrolled
|
||||
|
||||
Scenario: :scroll-page with --bottom-navigate
|
||||
When I run :scroll-perc 100
|
||||
@ -245,7 +245,7 @@ Feature: Scrolling
|
||||
|
||||
Scenario: :scroll-page with a very big value
|
||||
When I run :scroll-page 99999999999 99999999999
|
||||
Then the error "Numeric argument is too large for internal int representation." should be shown.
|
||||
Then the error "Numeric argument is too large for internal int representation." should be shown
|
||||
|
||||
Scenario: :scroll-page on a page without scrolling
|
||||
When I open data/hello.txt
|
||||
|
@ -9,19 +9,19 @@ Feature: Setting settings.
|
||||
|
||||
Scenario: Only a section
|
||||
When I run :set colors
|
||||
Then the error "set: Either both section and option have to be given, or neither!" should be shown.
|
||||
Then the error "set: Either both section and option have to be given, or neither!" should be shown
|
||||
|
||||
Scenario: Without value
|
||||
When I run :set colors statusbar.bg
|
||||
Then the error "set: The following arguments are required: value" should be shown.
|
||||
Then the error "set: The following arguments are required: value" should be shown
|
||||
|
||||
Scenario: Invalid section
|
||||
When I run :set blah blub foo
|
||||
Then the error "set: Section 'blah' does not exist!" should be shown.
|
||||
Then the error "set: Section 'blah' does not exist!" should be shown
|
||||
|
||||
Scenario: Invalid option
|
||||
When I run :set general blub foo
|
||||
Then the error "set: No option 'blub' in section 'general'" should be shown.
|
||||
Then the error "set: No option 'blub' in section 'general'" should be shown
|
||||
|
||||
Scenario: Toggling an option
|
||||
When I run :set general auto-save-config false
|
||||
@ -30,25 +30,25 @@ Feature: Setting settings.
|
||||
|
||||
Scenario: Toggling a non-bool option
|
||||
When I run :set colors statusbar.bg!
|
||||
Then the error "set: Attempted inversion of non-boolean value." should be shown.
|
||||
Then the error "set: Attempted inversion of non-boolean value." should be shown
|
||||
|
||||
Scenario: Getting an option
|
||||
When I run :set colors statusbar.bg magenta
|
||||
And I run :set colors statusbar.bg?
|
||||
Then the message "colors statusbar.bg = magenta" should be shown.
|
||||
Then the message "colors statusbar.bg = magenta" should be shown
|
||||
|
||||
Scenario: Using -p
|
||||
When I run :set -p colors statusbar.bg red
|
||||
Then the message "colors statusbar.bg = red" should be shown.
|
||||
Then the message "colors statusbar.bg = red" should be shown
|
||||
|
||||
Scenario: Using ! and -p
|
||||
When I run :set general auto-save-config false
|
||||
And I run :set -p general auto-save-config!
|
||||
Then the message "general auto-save-config = True" should be shown.
|
||||
Then the message "general auto-save-config = True" should be shown
|
||||
|
||||
Scenario: Setting an invalid value
|
||||
When I run :set general auto-save-config blah
|
||||
Then the error "set: Invalid value 'blah' - must be a boolean!" should be shown.
|
||||
Then the error "set: Invalid value 'blah' - must be a boolean!" should be shown
|
||||
|
||||
Scenario: Setting a temporary option
|
||||
# We don't actually check if the option is temporary as this isn't easy
|
||||
@ -64,32 +64,32 @@ Feature: Setting settings.
|
||||
|
||||
Scenario: Empty option with ? (issue 1109)
|
||||
When I run :set general ?
|
||||
Then the error "set: The following arguments are required: value" should be shown.
|
||||
Then the error "set: The following arguments are required: value" should be shown
|
||||
|
||||
Scenario: Invalid section and empty option with ? (issue 1109)
|
||||
When I run :set blah ?
|
||||
Then the error "set: The following arguments are required: value" should be shown.
|
||||
Then the error "set: The following arguments are required: value" should be shown
|
||||
|
||||
Scenario: Invalid option with ? (issue 1109)
|
||||
When I run :set general foo?
|
||||
Then the error "set: No option 'foo' in section 'general'" should be shown.
|
||||
Then the error "set: No option 'foo' in section 'general'" should be shown
|
||||
|
||||
Scenario: Invalid section/option with ? (issue 1109)
|
||||
When I run :set blah foo ?
|
||||
Then the error "set: Section 'blah' does not exist!" should be shown.
|
||||
Then the error "set: Section 'blah' does not exist!" should be shown
|
||||
|
||||
Scenario: Empty option with !
|
||||
When I run :set general !
|
||||
Then the error "set: The following arguments are required: value" should be shown.
|
||||
Then the error "set: The following arguments are required: value" should be shown
|
||||
|
||||
Scenario: Invalid section and empty option with !
|
||||
When I run :set blah !
|
||||
Then the error "set: The following arguments are required: value" should be shown.
|
||||
Then the error "set: The following arguments are required: value" should be shown
|
||||
|
||||
Scenario: Invalid option with !
|
||||
When I run :set general foo!
|
||||
Then the error "set: No option 'foo' in section 'general'" should be shown.
|
||||
Then the error "set: No option 'foo' in section 'general'" should be shown
|
||||
|
||||
Scenario: Invalid section/option with !
|
||||
When I run :set blah foo !
|
||||
Then the error "set: Section 'blah' does not exist!" should be shown.
|
||||
Then the error "set: Section 'blah' does not exist!" should be shown
|
||||
|
@ -116,7 +116,7 @@ Feature: Tab management
|
||||
Scenario: :tab-close with select-on-remove = previous and --opposite
|
||||
When I set tabs -> select-on-remove to previous
|
||||
And I run :tab-close --opposite
|
||||
Then the error "-o is not supported with 'tabs->select-on-remove' set to 'previous'!" should be shown.
|
||||
Then the error "-o is not supported with 'tabs->select-on-remove' set to 'previous'!" should be shown
|
||||
|
||||
Scenario: :tab-close should restore selection behaviour
|
||||
When I set tabs -> select-on-remove to right
|
||||
@ -164,13 +164,13 @@ Feature: Tab management
|
||||
|
||||
Scenario: :tab-only with --left and --right
|
||||
When I run :tab-only --left --right
|
||||
Then the error "Only one of -l/-r can be given!" should be shown.
|
||||
Then the error "Only one of -l/-r can be given!" should be shown
|
||||
|
||||
# :tab-focus
|
||||
|
||||
Scenario: :tab-focus with invalid index
|
||||
When I run :tab-focus foo
|
||||
Then the error "Invalid value foo." should be shown.
|
||||
Then the error "Invalid value foo." should be shown
|
||||
|
||||
Scenario: :tab-focus with index
|
||||
When I open data/numbers/1.txt
|
||||
@ -195,11 +195,11 @@ Feature: Tab management
|
||||
|
||||
Scenario: :tab-focus with invalid index
|
||||
When I run :tab-focus 23
|
||||
Then the error "There's no tab with index 23!" should be shown.
|
||||
Then the error "There's no tab with index 23!" should be shown
|
||||
|
||||
Scenario: :tab-focus with very big index
|
||||
When I run :tab-focus 99999999999999
|
||||
Then the error "Numeric argument is too large for internal int representation." should be shown.
|
||||
Then the error "Numeric argument is too large for internal int representation." should be shown
|
||||
|
||||
Scenario: :tab-focus with count
|
||||
When I open data/numbers/1.txt
|
||||
@ -213,7 +213,7 @@ Feature: Tab management
|
||||
|
||||
Scenario: :tab-focus with count and index
|
||||
When I run :tab-focus 2 with count 2
|
||||
Then the error "Both count and argument given!" should be shown.
|
||||
Then the error "Both count and argument given!" should be shown
|
||||
|
||||
Scenario: :tab-focus last
|
||||
When I open data/numbers/1.txt
|
||||
@ -230,7 +230,7 @@ Feature: Tab management
|
||||
Scenario: :tab-focus last with no last focused tab
|
||||
Given I have a fresh instance
|
||||
And I run :tab-focus last
|
||||
Then the error "No last focused tab!" should be shown.
|
||||
Then the error "No last focused tab!" should be shown
|
||||
|
||||
# tab-prev/tab-next
|
||||
|
||||
@ -276,13 +276,13 @@ Feature: Tab management
|
||||
When I set tabs -> wrap to false
|
||||
And I open data/numbers/1.txt
|
||||
And I run :tab-prev
|
||||
Then the error "First tab" should be shown.
|
||||
Then the error "First tab" should be shown
|
||||
|
||||
Scenario: :tab-next with last tab without wrap
|
||||
When I set tabs -> wrap to false
|
||||
And I open data/numbers/1.txt
|
||||
And I run :tab-next
|
||||
Then the error "Last tab" should be shown.
|
||||
Then the error "Last tab" should be shown
|
||||
|
||||
Scenario: :tab-prev on first tab with wrap
|
||||
When I set tabs -> wrap to true
|
||||
|
@ -39,7 +39,7 @@ def check_scrolled(quteproc, direction):
|
||||
assert y != 0
|
||||
|
||||
|
||||
@bdd.then("the page should not be scrolled.")
|
||||
@bdd.then("the page should not be scrolled")
|
||||
def check_not_scrolled(quteproc):
|
||||
x, y = _get_scroll_values(quteproc)
|
||||
assert x == 0
|
||||
|
@ -10,27 +10,27 @@ Feature: Yanking and pasting.
|
||||
Scenario: Yanking URLs to clipboard
|
||||
When I open data/yankpaste.html
|
||||
And I run :yank
|
||||
Then the message "Yanked URL to clipboard: http://localhost:(port)/data/yankpaste.html" should be shown.
|
||||
Then the message "Yanked URL to clipboard: http://localhost:(port)/data/yankpaste.html" should be shown
|
||||
And the clipboard should contain "http://localhost:(port)/data/yankpaste.html"
|
||||
|
||||
Scenario: Yanking URLs to primary selection
|
||||
When selection is supported
|
||||
And I open data/yankpaste.html
|
||||
And I run :yank --sel
|
||||
Then the message "Yanked URL to primary selection: http://localhost:(port)/data/yankpaste.html" should be shown.
|
||||
Then the message "Yanked URL to primary selection: http://localhost:(port)/data/yankpaste.html" should be shown
|
||||
And the primary selection should contain "http://localhost:(port)/data/yankpaste.html"
|
||||
|
||||
Scenario: Yanking title to clipboard
|
||||
When I open data/yankpaste.html
|
||||
And I wait for regex "Changing title for idx \d to 'Test title'" in the log
|
||||
And I run :yank --title
|
||||
Then the message "Yanked title to clipboard: Test title" should be shown.
|
||||
Then the message "Yanked title to clipboard: Test title" should be shown
|
||||
And the clipboard should contain "Test title"
|
||||
|
||||
Scenario: Yanking domain to clipboard
|
||||
When I open data/yankpaste.html
|
||||
And I run :yank --domain
|
||||
Then the message "Yanked domain to clipboard: http://localhost:(port)" should be shown.
|
||||
Then the message "Yanked domain to clipboard: http://localhost:(port)" should be shown
|
||||
And the clipboard should contain "http://localhost:(port)"
|
||||
|
||||
#### :paste
|
||||
@ -53,13 +53,13 @@ Feature: Yanking and pasting.
|
||||
Scenario: Pasting with empty clipboard
|
||||
When I put "" into the clipboard
|
||||
And I run :paste
|
||||
Then the error "Clipboard is empty." should be shown.
|
||||
Then the error "Clipboard is empty." should be shown
|
||||
|
||||
Scenario: Pasting with empty selection
|
||||
When selection is supported
|
||||
And I put "" into the primary selection
|
||||
And I run :paste --sel
|
||||
Then the error "Primary selection is empty." should be shown.
|
||||
Then the error "Primary selection is empty." should be shown
|
||||
|
||||
Scenario: Pasting in a new tab
|
||||
Given I open about:blank
|
||||
|
@ -7,51 +7,51 @@ Feature: Zooming in and out
|
||||
|
||||
Scenario: Zooming in
|
||||
When I run :zoom-in
|
||||
Then the message "Zoom level: 110%" should be shown.
|
||||
Then the message "Zoom level: 110%" should be shown
|
||||
And the zoom should be 110%
|
||||
|
||||
Scenario: Zooming out
|
||||
When I run :zoom-out
|
||||
Then the message "Zoom level: 90%" should be shown.
|
||||
Then the message "Zoom level: 90%" should be shown
|
||||
And the zoom should be 90%
|
||||
|
||||
Scenario: Zooming in with count
|
||||
When I run :zoom-in with count 2
|
||||
Then the message "Zoom level: 120%" should be shown.
|
||||
Then the message "Zoom level: 120%" should be shown
|
||||
And the zoom should be 120%
|
||||
|
||||
# https://github.com/The-Compiler/qutebrowser/issues/1118
|
||||
Scenario: Zooming in with very big count
|
||||
When I run :zoom-in with count 99999999999
|
||||
Then the message "Zoom level: 100%" should be shown.
|
||||
Then the message "Zoom level: 100%" should be shown
|
||||
And the zoom should be 100%
|
||||
|
||||
Scenario: Zooming out with count
|
||||
When I run :zoom-out with count 2
|
||||
Then the message "Zoom level: 50%" should be shown.
|
||||
Then the message "Zoom level: 50%" should be shown
|
||||
And the zoom should be 50%
|
||||
|
||||
Scenario: Setting zoom
|
||||
When I run :zoom 50
|
||||
Then the message "Zoom level: 50%" should be shown.
|
||||
Then the message "Zoom level: 50%" should be shown
|
||||
And the zoom should be 50%
|
||||
|
||||
Scenario: Setting zoom with count
|
||||
When I run :zoom with count 40
|
||||
Then the message "Zoom level: 40%" should be shown.
|
||||
Then the message "Zoom level: 40%" should be shown
|
||||
And the zoom should be 40%
|
||||
|
||||
Scenario: Resetting zoom
|
||||
When I set ui -> default-zoom to 42%
|
||||
And I run :zoom 50
|
||||
And I run :zoom
|
||||
Then the message "Zoom level: 42%" should be shown.
|
||||
Then the message "Zoom level: 42%" should be shown
|
||||
And the zoom should be 42%
|
||||
|
||||
Scenario: Setting zoom to invalid value
|
||||
When I run :zoom -1
|
||||
Then the error "Can't zoom -1%!" should be shown.
|
||||
Then the error "Can't zoom -1%!" should be shown
|
||||
|
||||
Scenario: Setting zoom with very big count
|
||||
When I run :zoom with count 99999999999
|
||||
Then the message "Zoom level: 99999999999%" should be shown.
|
||||
Then the message "Zoom level: 99999999999%" should be shown
|
||||
|
Loading…
Reference in New Issue
Block a user