summaryrefslogtreecommitdiffstats
path: root/third_party/WebKit/LayoutTests/fast/forms/form-attribute-not-in-document.html
blob: c913e2c8eaf7f91aa28f90b877b15c7386c88a62 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
<!DOCTYPE html>
<form id=myform></form>
<script src="../../resources/js-test.js"></script>
<script>
description('Inserting a form control with a form attribute into a non-document tree should not cause it to get a form owner.');

var input = document.createElement('input');
input.setAttribute('form', 'myform');
shouldBeNull('input.form');

var div = document.createElement('div');
div.appendChild(input);
shouldBeNull('input.form');
</script>