Proposed getting errors on build definiotion results

  • Tuesday, May 24, 2011 3:57 PM
     
     

    hi

    i created a new build definition and added a test project with 2 coded ui tests. its giving an error

    "Not Runnable CodedUITestRegistration  Failed to initialize the unit test extension 'urn:CodedUITest': A unit test extension is not registered for the following attribute: Microsoft.VisualStudio.TestTools.UITesting.CodedUITestAttribute. "

     

    Donot know whats the problem is ?

    Can any one help me out?

     

    thanks,

    katta

All Replies

  • Thursday, May 26, 2011 4:47 AM
    Moderator
     
     

    Hi Katta,

     

    Thanks for your post.

     

    If you want to run Code UI Test as part of Build Process, you have to install any test SKU on  the Build agent also configure the build agent as Interactive process. Please refer to this similar post: http://social.msdn.microsoft.com/Forums/en/vsautotest/thread/ef0e4db1-66c7-4aa7-ab86-a123d5f94e61.   


    John Qiao [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Thursday, May 26, 2011 8:13 AM
     
     

    Hi John

    THanks for your reply. I dont have any admin rights on TFS. Shall i ask my administrator to do this one. By the way i dnt know what is test SKU and how to install it on build agent?

     

    Thanks,

    Katta

  • Thursday, May 26, 2011 8:45 AM
    Moderator
     
     

    Hi Katta,

     

    Thanks for your reply.

     

    Please refer to Coded UI Test in a Team Build, there are step-by-step instructions with screenshots. 


    John Qiao [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Thursday, May 26, 2011 9:45 AM
     
     

    I did the same thing but still getting the above error. i dnt knw about test SKU thats why i asked. I need more info on build server and build agent

    Thanks,

    Katta

  • Thursday, May 26, 2011 10:15 AM
    Moderator
     
     

    Hi Katta,

     

    Thanks for your reply.

     

    SKU is Visual Studio Test Edition product. Please refer to: http://msdn.microsoft.com/en-us/library/bb385901.aspx.


    John Qiao [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Thursday, May 26, 2011 12:47 PM
     
     

    thanks john,

     

    I got vs 2010 premium version i am going to try build as interactive process now.

  • Thursday, May 26, 2011 12:52 PM
     
     

    Hi John,

    Could you solve this problem

     

     

    Hi every one,

     

    i am trying to run a test case which is automated as coded ui. i am trying to run this in test manager. My controller is running and agent is running. ALl view test run properties set in vs 2010. I am using windows server 2008 and premium vs 2010 version. When i run the test in test manager it is waiting for controller for ages. When i view the test log it displayed

     

     

    ID Date and time Message
    1 05/26/2011 13:32:38 Preparing to execute test run [206].
    2 05/26/2011 13:32:38 Test run is executed by Process: 'QTController', User: 'AGEUKDEV\Katta.Swathi', Controller: 'VMNMDEV34', Environment: 'envi'.
    3 05/26/2011 13:32:38 Loading the test settings for test run [206].
    4 05/26/2011 13:32:38 Adding test case [5052] to test run [206].
    5 05/26/2011 13:32:38 Error adding test case [5052] to test run: Exception has been thrown by the target of an invocation.
    6 05/26/2011 13:32:38 Failing 1 test(s) that could not be executed.
    7 05/26/2011 13:32:38 No automated tests of test run [206] are pending, queued, or in progress.

     

     

    can any one help me out. I searched in all forums and applied all solutions but there is no change.

     

     

    thanks,

    katta

  • Thursday, May 26, 2011 1:04 PM
     
     

    Hi John,

     

    As your anwer do i need to install vs 2010 premium on build server machine. bcoz i cant configure build agent and controllers on my machine as i am not having any admin rights on TFS which means i cannot able to go to Team foundation admin console page. On my machine i m having Vs2010 premium and test manager.  so on admin sys do we need to have test manager or is it okey to use vs 2010 premium only?

     

    Thanks ,

    katta

  • Friday, May 27, 2011 3:34 AM
    Moderator
     
     

    Hi Katta,

     

    Thanks for  your reply.

     

    As far as I know, Team Build invoke test edition to process test, and the test edition included in VS. If you only want to build your test using Team Build on build machine, you only need to install your VS 2010 premium(include Test Edition) on build machine.  

     

    There have a nice chart of the features in the different SKU’s at: http://www.ewaldhofman.nl/post/2009/10/19/VS-TFS-2010-Beta-2-has-arrived.aspx.

     

    For Test Manager issue, I suggest you to post it at http://social.msdn.microsoft.com/Forums/en-US/vsmantest/threads for quicker and better response, where MTM experts live in.

     


    John Qiao [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.


  • Friday, May 27, 2011 11:28 AM
     
     

    Hi John,

    I am sorry to irritate you again and agian. I have doine everything which you have mentioned above. I did build service as interactive  mode and installed test sku(vs2010 premium and test professional) on build machine. I tried with vsmdi file and local test settings file in automation test settings. but still getting same error for coded ui . COuld you please solve my problem . I must solve this problem.

     

    Thanks,

    Katta

  • Monday, May 30, 2011 2:39 AM
    Moderator
     
     

    Hi Katta,

     

    Thanks for your reply.

     

    I want to confirm with you that: your Code UI test can run completely using VS 2010 on the build machine? No any error? 


    John Qiao [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Tuesday, May 31, 2011 4:00 AM
    Moderator
     
     

    Hi Katta, 

     

    What about  the progress for this issue? 


    John Qiao [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Tuesday, May 31, 2011 8:06 AM
     
     

    Hi John,

     

    Sorry for the late reply. As its bank holiday i could not come back to this issue. i am back today. No i am not getting any errors when i run those coded ui on vs 2010. Dont know the issue what it is ,but getting errors for coded  ui tests. Could you help me out in this?

     

     

    Thanks,

    katta

  • Tuesday, May 31, 2011 8:10 AM
    Moderator
     
     

    Hi Katta,

     

    Thanks for your reply.

     

    What’s the detailed error message?


    John Qiao [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Tuesday, May 31, 2011 9:33 AM
     
      Has Code
    Overall Build Process
    
    00:00
    Update Build Number
    
    00:00
    Create the Drop Location
    
    00:41
    Run On Agent (reserved build agent AgeUk Build Agent)
    
    00:00
    Delete Test Results Directory
    
    00:00
    Delete Binaries Directory
    
    00:00
    Delete Workspace
    
    00:00
    Delete Sources Directory
    
    00:00
    Create Workspace
    
    00:00
    Get Workspace
    
    00:00
    Create Label
    Label xyz_20110531.5@$/AgeUk (version W10_1_VMNMTFS01;AGEUKDEV\!TFSBuildServer1) was successfully created.
    
    00:36
    Compile, Test, and Associate Changesets and Work Items
    
    00:36
    Compile and Test
    
    00:14
    If Local File Doesn't Exist
    
    00:14
    Run MSBuild for Project
    C:\Windows\Microsoft.NET\Framework64\v4.0.30319\MSBuild.exe /nologo /noconsolelogger "D:\Builds\1\AgeUk\xyz\Sources\testingprojects.sln" /m:1 /fl /flp:"logfile=D:\Builds\1\AgeUk\xyz\Sources\testingprojects.log;encoding=Unicode;verbosity=normal" /p:SkipInvalidConfigurations=true /p:OutDir="D:\Builds\1\AgeUk\xyz\Binaries\\" /p:VCBuildOverride="D:\Builds\1\AgeUk\xyz\Sources\testingprojects.sln.vsprops" /dl:WorkflowCentralLogger,"C:\Program Files\Microsoft Team Foundation Server 2010\Tools\Microsoft.TeamFoundation.Build.Server.Logger.dll";"Verbosity=Normal;BuildUri=vstfs:///Build/Build/5081;InformationNodeId=285843;TargetsNotLogged=GetNativeManifest,GetCopyToOutputDirectoryItems,GetTargetPath;TFSUrl=http://vmnmtfs01:8080/tfs/DefaultCollection;"*WorkflowForwardingLogger,"C:\Program Files\Microsoft Team Foundation Server 2010\Tools\Microsoft.TeamFoundation.Build.Server.Logger.dll";"Verbosity=Normal;"
    
    00:08
    Built $/AgeUk/KattasTest/New Folder/testingprojects.sln for default targets.
    
    00:06
    Built $/AgeUk/KattasTest/New Folder/testingprojects.csproj for default targets.
    MSBuild Log File
    
    00:22
    Run MSTest for Test Assemblies
    The MSTestActivity was invoked without a value for Platform or Flavor. The values Any CPU and Debug were used.
    C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\MSTest.exe /nologo /usestderr /testSettings:"D:\Builds\1\AgeUk\xyz\Sources\Local.testsettings" /searchpathroot:"D:\Builds\1\AgeUk\xyz\Binaries" /resultsfileroot:"D:\Builds\1\AgeUk\xyz\TestResults" /testcontainer:"D:\Builds\1\AgeUk\xyz\Binaries\testingprojects.dll" /publish:"http://vmnmtfs01:8080/tfs/DefaultCollection" /publishbuild:"vstfs:///Build/Build/5081" /teamproject:"AgeUk" /platform:"Any CPU" /flavor:"Debug" 
    Loading D:\Builds\1\AgeUk\xyz\Sources\Local.testsettings...
    Loading D:\Builds\1\AgeUk\xyz\Binaries\testingprojects.dll...
    Starting execution...
    
    Results        Top Level Tests
    -------        ---------------
    Not Runnable     testingprojects.Registartion.CodedUITestRegistration
    Not Runnable     testingprojects2.Localdirectory.CodedUITestLD
    0/2 test(s) Passed, 2 Not Runnable
    
    Summary
    -------
    Test Run Not Runnable.
    Not Runnable 2
    ---------------
    Total     2
    Results file: D:\Builds\1\AgeUk\xyz\TestResults\!TFSBuildServer1_VMNMTFS01 2011-05-31 10_30_25_Any CPU_Debug.trx
    Test Settings: Local
    Waiting to publish...
    Publishing results of test run !TFSBuildServer1@VMNMTFS01 2011-05-31 10:30:25_Any CPU_Debug to http://vmnmtfs01:8080/tfs/DefaultCollection...
    ..Publish completed successfully.
    
    00:00
    Handle MSTest Exception
    
    00:00
    Associate Changesets and Work Items
    
    00:01
    Get Impacted Tests, Index Sources and Publish Symbols
    
    00:00
    Get Impacted Tests
    
    00:00
    Index Sources
    C:\Program Files\Microsoft Team Foundation Server 2010\Tools\srctool.exe D:\Builds\1\AgeUk\xyz\Binaries\testingprojects.pdb -r
    C:\Program Files\Microsoft Team Foundation Server 2010\Tools\pdbstr.exe -w -p:D:\Builds\1\AgeUk\xyz\Binaries\testingprojects.pdb -i:C:\Users\!TFSBuildServer1\AppData\Local\Temp\tmpDAF2.tmp -s:srcsrv
    Skipped execution of Revert Workspace because of BuildReason Manual
    
    00:00
    Copy Files to Drop Location
    Skipped execution of Check In Gated Changes because of BuildReason Manual
    
  • Tuesday, May 31, 2011 9:35 AM
     
     

    Hi JOhn,

     

    Above is the Log file generated after the run. In test Results window i got  error like

     

    "Not Runnable CodedUITestRegistration  Failed to initialize the unit test extension 'urn:CodedUITest': A unit test extension is not registered for the following attribute: Microsoft.VisualStudio.TestTools.UITesting.CodedUITestAttribute. "

     

    If you need any more information let me know . Thanks for your patience. I really appreciate it.

    Thanks,

    Katta

  • Tuesday, May 31, 2011 4:01 PM
     
     

    Hi John,

     

    Have you find any solution  for this issue?

     

    Thanks,

    Katta

  • Wednesday, June 01, 2011 9:26 AM
    Moderator
     
     

    Hi Katta,

     

    Thanks for your reply.

     

    I tried to reproduce your scenario on my machine, but I didn’t occur that issue.

     

    You said that your Code UI test can run using VS 2010 completely. So I think it shouldn’t occur the CodeUITest not registered issue.

     

    How did you run CodeUITest using VS 2010 on Build machine? In Test View windows, right-click your CodeUITest and select Run Selection to execute it and can execute successfully?     

     

    And make sure the steps in that Code UI Test in a Team Build blog.  


    John Qiao [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Wednesday, June 01, 2011 10:48 AM
     
     
    Perfect . Yes i did like that. In Test View window right click on the method and runselection and it is passed and giving test results. but not in build.
  • Thursday, June 02, 2011 7:35 AM
    Moderator
     
     

    Hi Katta,

     

    Thanks for your reply. 

     

    On all build machine will occur the seam issue? 


    John Qiao [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Thursday, June 02, 2011 7:48 AM
     
     
    i have not checked that. i did only on machine. we have single licence for test professional which is installed on my machine. so i m the only person can run builds with coded ui.
  • Friday, June 03, 2011 9:02 AM
    Moderator
     
     

    Hi Katta,

     

    Thanks for your reply.

     

    This issue requires more troubleshooting and I can’t reproduce this scenario on my machine. If it is urgent issue, I suggest you to contact a Professional Support Service at http://support.microsoft.com/ to gain more support on this case.


    John Qiao [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Monday, June 06, 2011 8:03 AM
     
     

    Hi John,

     

    Thanks for your reply. Whom i can ask about this issue in support?

     

    Thanks,

    Katta

  • Tuesday, June 14, 2011 1:50 PM
     
     

    Hi John,

     

    FOr coded ui tests do i need to associate any test cases? Because i have added coded ui tests which i recorder from Vs2010,not from MTM.

     

    Regards,

    katta

  • Wednesday, June 15, 2011 4:00 AM
    Moderator
     
     

    Hi Katta,

     

    If you want to associate an exist Code UI Test to Test Case, you need to modify the Test Case’s action step in Test Manager(MTM).  


    John Qiao [MSFT]
    MSDN Community Support | Feedback to us
    Get or Request Code Sample from Microsoft
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.


  • Wednesday, June 15, 2011 10:16 AM
     
     

    Hi John,

     

    Thanks for your reply. What my question is to run coded ui tests in the build definition do i need to associate them with any test cases. Because i recorded all coded ui tests in Vs 2010 and added them build definition. SO is this the reason i m getting errors?

     

     

    Thanks,

    Katta

  • Friday, April 13, 2012 8:28 AM
     
     Proposed

    Hi Katta,

    don't know whether u solved it yet or not, I do run into  similar issue that  "Team BVT fail to init for case with Coded-UI-test"

    Anyway let me share how I resolved it

    1. Compose a Test Setting to Roles -> Test Execution Method -> Remote Execution
      and supply the only controller I have ( not available until I unregistered it  from Team Project Collection under TFS Test Controller 2010 configuration tools )
    2. Edit Build Definition to use that New Test Settings file
    3. (assuming your Test Agent are configured to run under interactive user mode

    Hope this help 

    Saxon.


    Saxon

    • Proposed As Answer by Sx Chan Friday, April 13, 2012 8:28 AM
    •