JustMock in TFS Build

6 posts, 0 answers
  1. Ron
    Ron avatar
    4 posts
    Member since:
    Mar 2013

    Posted 24 Mar 2015 Link to this post

    I am trying to setup a continuous integration process on our TFS server using the gated check-in method.  We have a number of existing tests which are using JustMock, so when we first tried to do this we received errors on the build that the profiler could not be started.  To remedy this I have been trying to follow the instructions at this link: http://www.telerik.com/help/justmock/integration-code-activity-workflow.html.  I have gotten to Step 2 and run into errors.  First when I tried to add the JustMock build workflow DLL to the custom toolbox I received an error stating that a dependant DLL could not be found.  One of our IT people found the missing DLL (Microsoft.TeamFoundation.Build.Client.dll) and by placing that in the same folder as the workflow DLL I was able to add the workflow DLL to the toolbox; however, when I attempted to drag the JustMock TestRunner tool into the workflow I received an error similar to the one I had gotten prior to adding the MS DLL to the folder, so I assumed I needed to add that DLL to the toolbox as well.  Adding the MS build client DLL threw an error stating that a reference could not be resolved and indicating that the reference was to a MS source control DLL.  I tried dragging the JustMock TestRunner onto the template again, and now I just have a red bar in the workflow stating "Could not generate view for JustMockTestRunner".

    Does anyone have any suggestions for how to solve this issue?

    TIA
    Ron L.
  2. Stefan
    Admin
    Stefan avatar
    198 posts

    Posted 25 Mar 2015 Link to this post

    Hello Ron,

    The DLL you mention should be installed as part of the "TFS 201x Object Model" package. This package is usually installed as part of Visual Studio. I don't know why you're missing it, but you can install it separately. If you tell me which version of TFS you're using, I can find the package installer for you.

    Most importantly, this is not a dependency that you need to lug around manually - it should come from GAC as part of the Object Model redistributable.

    Regards,
    Stefan
    Telerik
     

    See What's Next in App Development. Register for TelerikNEXT.

     
  3. DevCraft R3 2016 release webinar banner
  4. Ron
    Ron avatar
    4 posts
    Member since:
    Mar 2013

    Posted 25 Mar 2015 in reply to Stefan Link to this post

    Stefan
    We are using Visual Studio 2012 with TFS 2010.  Will the installation need to be done on all developer workstations, or only on the ones of people who are modifying the workflow?

    Thank you for the response,
    Ron L.
  5. Stefan
    Admin
    Stefan avatar
    198 posts

    Posted 25 Mar 2015 Link to this post

    Hello Ron,

    This is probably what you need:

    Team Foundation Server 2010 SP1 Object Model Installer

    It should be installed only by developers that edit the workflow.

    Regards,
    Stefan
    Telerik
     

    See What's Next in App Development. Register for TelerikNEXT.

     
  6. Ron
    Ron avatar
    4 posts
    Member since:
    Mar 2013

    Posted 26 Mar 2015 in reply to Stefan Link to this post

    Stefan

    Thank you for the response.  I will give that a try.

    Ron L.
  7. Ron
    Ron avatar
    4 posts
    Member since:
    Mar 2013

    Posted 31 Mar 2015 Link to this post

    Setfan

    I have gotten the Object Model installed on my system and was able to edit the workflow.  As I was editing the workflow, I noticed that many of the property value entries specified in Steps 3-5 did not have intellisense after the first "." was entered - I don't know if this is an indication of the problem below or not.  Once I completed the modifications to the workflow as specified in the "TFS Build Template Instructions" document, I checked in the workflow file, modified the build to use the new workflow, and queued a build.  When the build completed, it indicated errors in the build with the error message below.  Can you suggest steps for resolving this issue?

    Thank you,
    Ron L.

    Error Message:

    The build process failed validation. Details:  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.BuildNumber". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "DropBuild AndAlso Not String.IsNullOrEmpty(BuildDetail.DropLocation)". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.DropLocation". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.BuildNumber". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.BuildDefinition.Name". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "associatedChangesets". Type 'Changeset' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "associatedChangesets". Type 'Changeset' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "treatTestFailureAsBuildFailure And (BuildDetail.TestStatus = Microsoft.TeamFoundation.Build.Client.BuildPhaseStatus.Failed)". Type 'IBuildDetail' is not defined. 'Client' is not a member of 'Build'.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "ResultSummary = ReturnCodes.Passed". 'ResultSummary' is not declared. It may be inaccessible due to its protection level. 'ReturnCodes' is not declared. It may be inaccessible due to its protection level.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.TestStatus = Microsoft.TeamFoundation.Build.Client.BuildPhaseStatus.Unknown". Type 'IBuildDetail' is not defined. 'Client' is not a member of 'Build'.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.CompilationStatus = Microsoft.TeamFoundation.Build.Client.BuildPhaseStatus.Unknown". Type 'IBuildDetail' is not defined. 'Client' is not a member of 'Build'.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "testAssemblies.Count() > 0". 'Count' is not a member of 'System.Collections.Generic.IEnumerable(Of String)'.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.Uri.ToString()". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "testAssemblies.ToArray()". 'ToArray' is not a member of 'System.Collections.Generic.IEnumerable(Of String)'.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.TeamProject". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.Uri.ToString()". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "ResultSummary". 'ResultSummary' is not declared. It may be inaccessible due to its protection level.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "testAssemblies.ToArray()". 'ToArray' is not a member of 'System.Collections.Generic.IEnumerable(Of String)'.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.TeamProject". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.Uri.ToString()". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "ResultSummary". 'ResultSummary' is not declared. It may be inaccessible due to its protection level.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.TeamProject". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "BuildDetail.RequestedFor". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "String.Format("Build Failure in Build: {0}", BuildDetail.BuildNumber)". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "Not String.IsNullOrEmpty(BuildDetail.DropLocation)". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "If (platformConfiguration.IsEmpty Or BuildSettings.PlatformConfigurations.Count = 1, BuildDetail.DropLocation + "\logs", If (platformConfiguration.IsPlatformEmptyOrAnyCpu, BuildDetail.DropLocation + "\logs\" + platformConfiguration.Configuration, BuildDetail.DropLocation + "\logs\" + platformConfiguration.Platform + "\" + platformConfiguration.Configuration))". Type 'IBuildDetail' is not defined. Type 'IBuildDetail' is not defined. Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "String.Format("{0}@$/{1}", LabelName, BuildDetail.BuildDefinition.TeamProject)". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "String.Format("$/{0}", BuildDetail.BuildDefinition.TeamProject)". Type 'IBuildDetail' is not defined.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "WorkspaceName.Length > Microsoft.TeamFoundation.VersionControl.Common.RepositoryConstants.MaxWorkspaceNameSize". 'VersionControl' is not a member of 'TeamFoundation'.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "WorkspaceName.Substring(0, Microsoft.TeamFoundation.VersionControl.Common.RepositoryConstants.MaxWorkspaceNameSize).TrimEnd()". 'VersionControl' is not a member of 'TeamFoundation'.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "String.Format("The workspace name '{0}' exceeds the maximum allowed limit of '{1}' characters. Truncating it to match the maximum limit.", WorkspaceName, Microsoft.TeamFoundation.VersionControl.Common.RepositoryConstants.MaxWorkspaceNameSize)". 'VersionControl' is not a member of 'TeamFoundation'.  Validation Error: The private implementation of activity '1: DynamicActivity' has the following validation error:   Compiler error(s) encountered processing expression "String.Format("{0}_{1}_{2}", BuildDetail.BuildDefinition.Id, Microsoft.TeamFoundation.LinkingUtilities.DecodeUri(BuildAgent.Uri.AbsoluteUri).ToolSpecificId, BuildAgent.ServiceHost.Name)". Type 'IBuildDetail' is not defined. 'LinkingUtilities' is not a member of 'TeamFoundation'. Type 'IBuildAgent' is not defined. Type 'IBuildAgent' is not defined.  



Back to Top
DevCraft R3 2016 release webinar banner