Forum Discussion

scsvel's avatar
scsvel
Frequent Contributor
14 years ago

SilverLight Application Testing - Considerations while building the AUT

Hi all,



I am on the way to automating silverlight application. I started to spy the objects to code. But TC says message like

"Application is not prepared.... etc". Have attached the screenshot of the message.



What are the points to consider while building the application under test to make support with TC.

Using TC Version: 8.50.619.7 and SilverLight Version: 4.0.60531.0



Any ideas?

Or TC itself will support the controls without doing anything while building the AUT?



Thanks...
  • irina_lukina's avatar
    irina_lukina
    Super Contributor

    Hi Shanmugavel,


    Since TestComplete 8.50, Silverlight applications are patched automatically ("on-the-fly"). However, there are some limitations that prevent TestComplete from patching a Silverlight application automatically. Most likely, this is your case. Here are the possible reasons:

    1. The used browser is not Firefox or Internet Explorer. As far as I can see from your screenshot, this limitation is not true for your application, so, it's just for your information.

    2. The tested web page downloads the .xap file directly from the web server. For example, if the browser moves this file to the cache memory before TestComplete starts working with this file, the file will be downloaded from the cache memory and auto-patching will fail.

    3. The HTTPS protocol is used. In this case, auto-patching will not work.

    4. One more reason is that the Silverlight application was launched before TestComplete. In this case, auto-patching will not work. The fact is that TestComplete tries to patch the application automatically when it downloads the .xap file.

    5. TestComplete also does not recognize those Silverlight applications that were not packed to a .xap file and use the .xaml file as the source file. As I can see from your screenshot, this limitation is not true for you, so, it's just for your information.


    If none of the above-mentioned is true, please try doing the following:

    * Upgrade to the latest version of TestComplete (ver. 8.60). You can download it from our web site: http://smartbear.com.

    * If upgrading doesn't help, try patching the .xap file manually and reload it to the web server. For detailed instructions on how to do this, please see the Preparing Silverlight Applications for Testing help topic.

    * If the approach described in this topic doesn't help, please send a request with a sample application to our support team, so that we can reproduce the problem and find a solution faster.


    Thanks.