This really tripped me up yesterday, My "Vim default" is to use tabs.
This (where `!···` is a tab) does not work as you'll hope it works:
Scenario: Retrying a failed download when the directory didn't exist (issue 2445)
When I download http://localhost:(port)/data/downloads/download.bin to <path>
And I wait for the error "Download error: No such file or directory: *"
And I make the directory <mkdir>
And I run :download-retry
!···!···And I wait until the download is finished
Then the downloaded file <expected> should exist
Examples:
| path | mkdir | expected |
| asd/zxc/ | asd/zxc | asd/zxc/download.bin |
Unfortunately, pytest-bdd uses the "Python 2 behaviour" of "expand all
tabs to 8 spaces", and doesn't give any errors on strange/inconsistent
whitespace. It can cause very confusing errors.
We now use click() or focus() in JS if possible, or manually follow links in a
href attribute.
While this probably introduces some new corner cases, it fixes a handful of
older ones:
- window.open() in JS can now be handled correctly as we don't need hacks in
createWindow anymore.
- Focusing input fields with images now works - fixes#1613, #1879
- Hinting now works better on QtWebEngine with Qt 5.8 - fixes#2273
Also see #70.
With QtWebEngine, inserting text into the field is async, so if our
test runs too fast, it would fail. Now we instead log stuff via JS on
changes insteaad, and wait for those log messages in the tests.
With the addition of :window-only, it's no longer necessary to use
"Given I have a fresh instance" to clean up previous windows. This
greatly cuts down on the amount of process restarts that need to happen
to complete a full testing cycle.
I also made one of the tests more robust against order alterations, and
removed some unnecessary extra commands that were already implied by the
background on others.
The test for inserting text at a specific position failed because
<Ctrl+Right> doesn't behave the same on Windows and Linux. This changes
it to move the cursor using other keys.
Changes :yank's flag arguments to a positional "what" argument
specifying the object to be yanked. Including "selection" as a
possibility allows for the replacement of :yank-selected with
:yank selection.