[LDTP-Dev] Cbo object not found

Nagappan Alagappan nagappan at gmail.com
Tue Jan 15 16:50:52 PST 2013


Hi Damien,

Thanks for the bug report, I could reproduce with Win7SP1 US-English. Fixed
in git head.

Thanks
Nagappan


On Tue, Jan 15, 2013 at 12:07 AM, <damien.aiello at bull.net> wrote:

> Hi,
>
> I'm trying to make a proof of concept for a further benchmark.
>
> What I want to do (under Windows XP) :
>  - open notepad,
>  - write a few words,
>  - save the documents somewhere on the disks.
>
> My code (work in progress) :
> #-*- coding:utf-8 -*-
>
> from ldtp import *
> from ldtputils import *
> import string
> import random
>
> try:
>         launchapp("notepad", lang= "fr_FR.utf8")
>
>         if waittillguiexist("frmSanstitre-Bloc-notes") == 0:
>                 raise LdtpExecutionError("Le bloc-notes n'est pas ouvert")
>
>         enterstring("frmSanstitre-Bloc-notes", "strTest", "abc123")
>
>         selectmenuitem("frmSanstitre-Bloc-notes",
> "mnuFichier;mnuEnregistrersous...")
>
>         if waittillguiexist ("frmEnregistrersous") == 0:
>                 raise LdtpExecutionError ("Impossible d'ouvrir la boite de
> dialogue 'Fichier -> Enregistrer sous...'")
>
>         settextvalue("frmEnregistrersous", "cboNomdufichier", "test.txt")
>
>
> except LdtpExecutionError, msg:
>         raise
>
> This code gives me the following error :
> Unable to find Object: cboNomdufichier
>
> But I can see this object if I do something like :
> listeObjets=getobjectlist("frmEnregistrersous")
>         for i in listeObjets:
>                 if guiexist("frmEnregistrersous", i):
>                         print i
>
> What I am doing wrong ?
>
> PS : I'm working with Cobra3 and Python 2.7 for Windows.
>
>
> Damien Aiello
>
> Bull, 1 rue de Provence
> 38130 Echirolles
> Tél. : 04 76 29 71 36
> _______________________________________________
> LDTP-dev mailing list
> LDTP-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/ldtp-dev
>
>


-- 
Cross platform GUI testing
Linux Desktop (GUI Application) Testing Project -
http://ldtp.freedesktop.org
Cobra - Windows GUI Automation tool - https://github.com/ldtp/cobra
ATOMac - Mac GUI Automation tool - https://github.com/pyatom/pyatom
http://nagappanal.blogspot.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/ldtp-dev/attachments/20130115/4940cac1/attachment.html>


More information about the LDTP-dev mailing list