Add test for tab-bg focus
This commit is contained in:
parent
262cea8e75
commit
bc9f178a08
25
tests/end2end/data/hints/link_input.html
Normal file
25
tests/end2end/data/hints/link_input.html
Normal file
@ -0,0 +1,25 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Simple link and input</title>
|
||||
<script type="text/javascript">
|
||||
function setup_event_listener() {
|
||||
var elem = document.getElementById('qute-input-existing');
|
||||
console.log(elem);
|
||||
elem.addEventListener('input', function() {
|
||||
console.log("contents: " + elem.value);
|
||||
});
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body onload="setup_event_listener()">
|
||||
<a href="/data/hello.txt" id="link">Follow me!</a>
|
||||
<form><input id="qute-input"></input></form>
|
||||
With padding:
|
||||
<form><input type="text" style="padding-left: 20px;"></input></form>
|
||||
With existing text (logs to JS)::
|
||||
<form><input id="qute-input-existing" value="existing"></input></form>
|
||||
</body>
|
||||
</html>
|
@ -203,6 +203,17 @@ Feature: Using hints
|
||||
And I run :fake-key new
|
||||
Then the javascript message "contents: existingnew" should be logged
|
||||
|
||||
Scenario: Typing input with existing text after opening a bg tab
|
||||
When I open data/hints/link_input.html
|
||||
And I run :click-element id qute-input-existing
|
||||
And I wait for "Entering mode KeyMode.insert *" in the log
|
||||
And I run :leave-mode
|
||||
And I hint with args "all tab-bg" and follow a
|
||||
And I wait until data/hello.txt is loaded
|
||||
And I run :enter-mode insert
|
||||
And I run :fake-key -g new
|
||||
Then the javascript message "contents: existingnew" should be logged
|
||||
|
||||
### iframes
|
||||
Scenario: Using :follow-hint inside an iframe
|
||||
When I open data/hints/iframe.html
|
||||
|
Loading…
Reference in New Issue
Block a user