Hmm, not really. In fact you should try to evaluate the XPath in a
browser for instance in Firefox with XPather or WebTestRecorder.
Cheers,
Marc.
--
Blog: http://mguillem.wordpress.com
Gert Pauwels wrote:
is this sufficient:
<li><a href="javascript: void(0);" id="menu-item.my_work.path">Mon travail</a> <ul><li><a href="screen/view.do?screen=EIM_InvestigatorHomePage&clearReplacementsContainer=true&clearLocks=true&csrftkn=1190777609
<view-source:http://leuaix0202:9081/norkom/screen/view.do?screen=EIM_InvestigatorHomePage&clearReplacementsContainer=true&clearLocks=true&csrftkn=1190777609>" onclick="return cursorWait(this)" id="menu-item.my_work.path:menu-item.home.path">Page
d'accueil</a></li><li><a href="javascript: void(0);" id="menu-item.my_work.path:menu-item.my_alerts.path">Mes alertes de détection</a> <ul><li><a href="screen/view.do?screen=EIM_Alert_MyAlerts&clearLocks=true&csrftkn=1190777609
<view-source:http://leuaix0202:9081/norkom/screen/view.do?screen=EIM_Alert_MyAlerts&clearLocks=true&csrftkn=1190777609>" onclick="return cursorWait(this)" id="menu-item.my_work.path:menu-item.my_alerts.path:menu-item.my_alerts.path">Mes alertes de détection</a></li>
Gert
> From: [email protected]
> To: [email protected]
> Subject: Re: [Webtest] Tests in French
> Date: Tue, 15 Jun 2010 16:50:34 +0200
>
> Hi,
>
> > <!-- Check the position and the text of top-level menu item-->
> > <clickLink xpath="//div/ul/li[contains(@id,
> > 'menu')]...@{level1position}]/a[text()='@{level1}']"/>
>
> here you will have a problem when level1 contains a quote because in
> this case the XPath expression won't be valid anymore. If " is unlikely
> to appear, you should be able to use
>
> <clickLink xpath='//div/ul/li[contains(@id,
> "menu")]...@{level1position}]/a[text()="@{level1}"]'/>
>
> In this case you will have troubles when level1 contains a " and you
> won't have any problems when it contains a '.
>
> >
> > And while the last one above succeeds, the following does not:
> > <checkMenuItem level1="Rapports" level1position="5"
> > level2="Alertes détection" level2position="1"/>
>
> this is a special feature of WebTest: it detects that "Alertes
> détection" has been badly translated and doesn't really sound French ;-)
>
> > I am *assuming* that this is due to the accented characters, but I
> > cannot confirm that.
>
> It shouldn't. Can you provide the HTML code of the <a> tag?
>
> Cheers,
> Marc.
> --
> Blog: http://mguillem.wordpress.com
>
> _______________________________________________
> WebTest mailing list
> [email protected]
> http://lists.canoo.com/mailman/listinfo/webtest
------------------------------------------------------------------------
Hotmail: Powerful Free email with security by Microsoft. Get it now.
<https://signup.live.com/signup.aspx?id=60969>
_______________________________________________
WebTest mailing list
[email protected]
http://lists.canoo.com/mailman/listinfo/webtest