Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(61)

Unified Diff: third_party/WebKit/LayoutTests/fast/forms/text/text-change-event-after-updating-default.html

Issue 2452903002: INPUT element: Updating value to the previous defaultValue should dispatch "change" event. (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLInputElement.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/fast/forms/text/text-change-event-after-updating-default.html
diff --git a/third_party/WebKit/LayoutTests/fast/forms/text/text-change-event-after-updating-default.html b/third_party/WebKit/LayoutTests/fast/forms/text/text-change-event-after-updating-default.html
new file mode 100644
index 0000000000000000000000000000000000000000..9fb90b05538765e128ccd65ba46e88fa4f9dc95a
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/forms/text/text-change-event-after-updating-default.html
@@ -0,0 +1,17 @@
+<!DOCTYPE html>
+<script src="../../../resources/testharness.js"></script>
+<script src="../../../resources/testharnessreport.js"></script>
+<input value="a">
+<script>
+test(() => {
+ var input = document.querySelector('input');
+ input.setAttribute('value', 'b');
+ input.focus();
+ input.select();
+ eventSender.keyDown('a');
+ var didDispatchChange = false;
+ input.onchange = () => { didDispatchChange = true; }
+ input.blur();
+ assert_true(didDispatchChange);
+}, 'crbug.com/659499: Updating INPUT value to the previous defaultValue should dispatch "change" event.');
+</script>
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLInputElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698