| OLD | NEW | 
|---|
| (Empty) |  | 
|  | 1 <html> | 
|  | 2 <head> | 
|  | 3 <script src="../../../resources/js-test.js"></script> | 
|  | 4 <style> | 
|  | 5 input:focus { | 
|  | 6     background: blue; | 
|  | 7 } | 
|  | 8 </style> | 
|  | 9 <body> | 
|  | 10 <input id="test" type="date"> | 
|  | 11 <a></a> | 
|  | 12 <script> | 
|  | 13 description('Setting value onBlur, should not keep element in focus.'); | 
|  | 14 var testInput = document.getElementById('test'); | 
|  | 15 testInput.addEventListener('blur', function() { | 
|  | 16     testInput.value = ''; | 
|  | 17 }); | 
|  | 18 | 
|  | 19 testInput.value = '2012-02-01'; | 
|  | 20 testInput.focus(); | 
|  | 21 var style = window.getComputedStyle(testInput); | 
|  | 22 shouldBeEqualToString('style.getPropertyValue("background-color")', 'rgb(0, 0, 2
    55)'); | 
|  | 23 testInput.blur(); | 
|  | 24 style = window.getComputedStyle(testInput); | 
|  | 25 shouldBeEqualToString('style.getPropertyValue("background-color")', 'rgb(255, 25
    5, 255)'); | 
|  | 26 </script> | 
|  | 27 </body> | 
|  | 28 </html> | 
| OLD | NEW | 
|---|