1<?php 2 3class TestPagebreakTableBr extends GenericTest { 4 /** 5 * Checks if it is possible to make an incorrect page break in a table with 6 * different font size in different cells 7 */ 8 function testPagebreakTableBr1() { 9 $media = new Media(array('width' => 100, 'height' => 200/mm2pt(1)), 10 array('top'=>0, 'bottom'=>0, 'left'=>0, 'right'=>0)); 11 $tree = $this->runPipeline(' 12<html> 13<head> 14body { 15 font-size: 10pt; 16 line-height: 1; 17 padding: 0; 18 margin: 0; 19} 20 21td.small { 22 font-size: 20pt; 23} 24</style> 25</head> 26<body> 27<table cellpadding="0" cellspacing="0"> 28<tr> 29<td> 30SMALL<br/> 31SMALL<br/> 32SMALL<br/> 33SMALL<br/> 34SMALL<br/> 35</td> 36</tr> 37</table> 38</body> 39</html> 40', $media); 41 42 /** 43 * Calculate page heights 44 */ 45 $locations = PageBreakLocator::_getBreakLocations($tree); 46 $this->assertEqual(count($locations), 6); 47 } 48} 49 50?>