Hello,

I can confirm this HtmlUnit bug. Therefore, it's hard to fix.

You could bypass this issue by using 
assertTableRowsMatch("TABLE_RISK_BIOMARKERS_EXTRA",
0, new String[][] { new String[] { "Disease History", "Coronary
Heart Disease (CHD)*Other Cardiovascular Disease*Diabetes*Stroke" } });

But you should also open a bug on jwebunit sourceforge page to trace the 
evolution of this bug.

++
Julien

----- Message d'origine ----
De : "Parham, Clinton" <[EMAIL PROTECTED]>
À : [email protected]
Envoyé le : Lundi, 15 Janvier 2007, 22h42mn 52s
Objet : [Jwebunit-users] assertTableRowsEqual semicolon behavior




 
 


<!--

 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
text-decoration:underline;}
span.EmailStyle17
        {font-family:Arial;
color:windowtext;}
 _filtered {
margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
        {}
-->






JWebUnit Users:


 


I have a table containing a cell with semicolon separated
text. When I try asserting its contents with assertTableRowsEqual, the test
fails with the error below. For some reason, a space is inserted just before
each semicolon. I don’t see the space in my HTML or my assert code. Where
is it coming from?


 


junit.framework.AssertionFailedError: Coronary Heart Disease
(CHD); Other Cardiovascular Disease; Diabetes; Stroke do not equal Coronary
Heart Disease (CHD) ; Other Cardiovascular Disease ; Diabetes ; Stroke


 


Here’s my code (JWebUnit 1.4):


 


public void testMe() {


beginAt("/test.htm");


assertTableRowsEqual("TABLE_RISK_BIOMARKERS_EXTRA",
0, new String[][] { new String[] { "Disease History", "Coronary
Heart Disease (CHD); Other Cardiovascular Disease; Diabetes; Stroke" } });


}


 


And here’s test.htm


<body>


<table border="1" cellspacing="0"
width="100%" id="TABLE_RISK_BIOMARKERS_EXTRA">


  <tr>


    <td>Disease
History</td>


    <td><a
id="HEART_DISEASE_MEMBER" href>Coronary Heart Disease
(CHD)</a><a id="CARDIOVASCULAR_OTHER" href>; Other
Cardiovascular Disease</a><a id="DIABETES_MEMBER" href="">;
Diabetes</a><a id="STROKE_MEMBER" href>; Stroke</a></td>


  </tr>


</table>


</body>


 





-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Jwebunit-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jwebunit-users







        

        
                
___________________________________________________________________________ 
Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions ! 
Profitez des connaissances, des opinions et des expériences des internautes sur 
Yahoo! Questions/Réponses 
http://fr.answers.yahoo.com
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Jwebunit-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jwebunit-users

Reply via email to