1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171
|
Feature: Going back and forward.
Testing the :back/:forward commands.
Scenario: Going back/forward
Given I open data/backforward/1.txt
When I open data/backforward/2.txt
And I run :tab-only
And I run :back
And I wait until data/backforward/1.txt is loaded
And I reload data/backforward/1.txt
And I run :forward
And I wait until data/backforward/2.txt is loaded
And I reload data/backforward/2.txt
Then the session should look like:
"""
windows:
- tabs:
- history:
- url: http://localhost:*/data/backforward/1.txt
- active: true
url: http://localhost:*/data/backforward/2.txt
"""
# https://travis-ci.org/qutebrowser/qutebrowser/jobs/157941720
@qtwebengine_flaky
Scenario: Going back in a new tab
Given I open data/backforward/1.txt
When I open data/backforward/2.txt
And I run :tab-only
And I run :back -t
And I wait until data/backforward/1.txt is loaded
Then the session should look like:
"""
windows:
- tabs:
- history:
- url: http://localhost:*/data/backforward/1.txt
- active: true
url: http://localhost:*/data/backforward/2.txt
- active: true
history:
- active: true
url: http://localhost:*/data/backforward/1.txt
- url: http://localhost:*/data/backforward/2.txt
"""
Scenario: Going back in a new tab without history
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
And the session should look like:
"""
windows:
- tabs:
- active: true
history:
- active: true
url: http://localhost:*/data/backforward/1.txt
"""
Scenario: Going back in a new background tab
Given I open data/backforward/1.txt
When I open data/backforward/2.txt
And I run :tab-only
And I run :back -b
And I wait until data/backforward/1.txt is loaded
Then the session should look like:
"""
windows:
- tabs:
- active: true
history:
- url: http://localhost:*/data/backforward/1.txt
- active: true
url: http://localhost:*/data/backforward/2.txt
- history:
- active: true
url: http://localhost:*/data/backforward/1.txt
- url: http://localhost:*/data/backforward/2.txt
"""
@flaky
Scenario: Going back with count.
Given I open data/backforward/1.txt
When I open data/backforward/2.txt
And I open data/backforward/3.txt
And I run :tab-only
And I run :back with count 2
And I wait until data/backforward/1.txt is loaded
And I reload data/backforward/1.txt
Then the session should look like:
"""
windows:
- tabs:
- history:
- active: true
url: http://localhost:*/data/backforward/1.txt
- url: http://localhost:*/data/backforward/2.txt
- url: http://localhost:*/data/backforward/3.txt
"""
Scenario: Going back too much with count.
Given I open data/backforward/1.txt
When I open data/backforward/2.txt
And I open data/backforward/3.txt
And I run :back with count 3
Then the error "At beginning of history." should be shown
Scenario: Going back with very big count.
Given I open data/backforward/1.txt
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
@qtwebengine_flaky
Scenario: Going back in a new window
Given I clean up open tabs
When I open data/backforward/1.txt
And I open data/backforward/2.txt
And I run :back -w
And I wait until data/backforward/1.txt is loaded
Then the session should look like:
"""
windows:
- tabs:
- active: true
history:
- url: about:blank
- url: http://localhost:*/data/backforward/1.txt
- active: true
url: http://localhost:*/data/backforward/2.txt
- tabs:
- active: true
history:
- url: about:blank
- active: true
url: http://localhost:*/data/backforward/1.txt
- url: http://localhost:*/data/backforward/2.txt
"""
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
Scenario: Going back without history and --quiet
Given I open data/backforward/1.txt
When I run :back --quiet
Then "At beginning of history." should be logged
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
Scenario: Going forward without history and --quiet
Given I open data/backforward/1.txt
When I run :forward --quiet
Then "At end of history." should be logged
@qtwebengine_skip # Getting 'at beginning of history' when going back
Scenario: Going forward too much with count.
Given I open data/backforward/1.txt
When I open data/backforward/2.txt
And I open data/backforward/3.txt
And I run :back with count 2
And I run :forward with count 3
Then the error "At end of history." should be shown
|