col_removal.html (864B)
1 <!doctype html> 2 <title>Table grid syncs after COL removal</title> 3 <link rel="author" href="mailto:atotic@google.com"> 4 <script src="/resources/testharness.js"></script> 5 <script src="/resources/testharnessreport.js"></script> 6 <link rel="help" href="https://crbug.com/1191940"> 7 8 <style> 9 main td { 10 width:30px; 11 height:30px; 12 padding:0; 13 } 14 </style> 15 <main> 16 <table style="border-collapse: collapse;"> 17 <col style="border: 2px solid green;"></col> 18 <col id="target" style="border: 50px solid red;"></col> 19 <td>x</td> 20 <td>x</td> 21 </table> 22 </main> 23 <script> 24 test(() => { 25 let table = document.querySelector("main table"); 26 document.body.offsetTop; 27 assert_equals(table.offsetWidth, 162); 28 document.getElementById('target').remove(); 29 assert_equals(table.offsetWidth, 64, "table shrinks after column is removed"); 30 }); 31 </script>