<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:media="http://search.yahoo.com/mrss/"><channel><title><![CDATA[continuous integration - Alexander Development]]></title><description><![CDATA[continuous integration - Alexander Development]]></description><link>https://alexanderdevelopment.net/</link><image><url>https://alexanderdevelopment.net/favicon.png</url><title>continuous integration - Alexander Development</title><link>https://alexanderdevelopment.net/</link></image><generator>Ghost 1.20</generator><lastBuildDate>Fri, 24 Apr 2026 14:24:45 GMT</lastBuildDate><atom:link href="https://alexanderdevelopment.net/tag/continuous-integration/rss/" rel="self" type="application/rss+xml"/><ttl>60</ttl><item><title><![CDATA[Running Dynamics 365 Configuration Data Mover jobs in VSTS builds]]></title><description><![CDATA[<div class="kg-card-markdown"><p>In today's post I will show how to use my <a href="https://alexanderdevelopment.net/tag/configuration-data-mover/">Dynamics 365 Configuration Data Mover</a> utility for synchronizing configuration data between CRM orgs as part of a <a href="https://www.visualstudio.com/team-services/">Visual Studio Team Services</a> build.</p>
<ol>
<li>Download the latest version of the Configuration Data Mover utility's CLI tool from my repository on GitHub here:</li></ol></div>]]></description><link>https://alexanderdevelopment.net/post/2017/09/12/running-dynamics-365-configuration-data-mover-jobs-in-vsts-builds/</link><guid isPermaLink="false">5a5837246636a30001b978e1</guid><category><![CDATA[Microsoft Dynamics CRM]]></category><category><![CDATA[Dynamics 365]]></category><category><![CDATA[Configuration Data Mover]]></category><category><![CDATA[continuous integration]]></category><dc:creator><![CDATA[Lucas Alexander]]></dc:creator><pubDate>Tue, 12 Sep 2017 12:00:00 GMT</pubDate><media:content url="https://alexanderdevelopment.net/content/images/2017/09/chrome_2017-09-11_12-49-49-1.png" medium="image"/><content:encoded><![CDATA[<div class="kg-card-markdown"><img src="https://alexanderdevelopment.net/content/images/2017/09/chrome_2017-09-11_12-49-49-1.png" alt="Running Dynamics 365 Configuration Data Mover jobs in VSTS builds"><p>In today's post I will show how to use my <a href="https://alexanderdevelopment.net/tag/configuration-data-mover/">Dynamics 365 Configuration Data Mover</a> utility for synchronizing configuration data between CRM orgs as part of a <a href="https://www.visualstudio.com/team-services/">Visual Studio Team Services</a> build.</p>
<ol>
<li>Download the latest version of the Configuration Data Mover utility's CLI tool from my repository on GitHub here: <a href="https://github.com/lucasalexander/AlexanderDevelopment.ConfigDataMover/releases">https://github.com/lucasalexander/AlexanderDevelopment.ConfigDataMover/releases</a>.<br>
Any version from 2.2 onward should work, and make sure you get the &quot;AlexanderDevelopment.ConfigDataMover.Cli.zip&quot; file.</li>
<li>Extract everything from the zip archive and add the entire directory to your source code repository. I have historically used a &quot;tools&quot; directory that contains various utilities, so I keep the Data Mover CLI tool in its own subdirectory there.</li>
<li>Add a directory to your source code repository to hold configuration data mover job files and JSON data extracts. I call mine &quot;data.&quot;</li>
<li>Set up a data mover job using the GUI tool. You can create a job that syncs data between two CRM orgs or a job that reads from a file source. I prefer to use file sources for deployments because then I don't have a dependency on the development org, and also the configuration data can be kept under source control. You can also save your connection parameters in the job file or pass them to the Data Mover at run time.</li>
<li>After you create and test your data mover job, save a copy of the XML job file to your source control &quot;data&quot; directory.</li>
<li><em>(This step is only required for file sources when you are saving the connection parameters in the job file.)</em> Open the XML file in a text editor and find the &lt;ConnectionDetails&gt; node toward the bottom. There will be a &quot;source&quot; attribute that you need to make sure is set to a relative path to the JSON data file from the location of your AlexanderDevelopment.ConfigDataMover.Cli.exe assembly. Because of how I have my directory structure set up in source control, the a JSON file named &quot;alm-test.json&quot; has &quot;....\data\alm-test.json&quot; as its relative path. Here's a screenshot of my directory structure for reference:<br>
<img src="https://alexanderdevelopment.net/content/images/2017/09/chrome_2017-09-11_12-48-14.png#img-thumbnail" alt="Running Dynamics 365 Configuration Data Mover jobs in VSTS builds"></li>
<li>Commit your changes to your VSTS instance. I am using Git, but this should work for TFS, too.</li>
<li>Create a new build and add a batch script step.</li>
<li>Configure the batch script step to run the AlexanderDevelopment.ConfigDataMover.Cli.exe assembly you pushed to source control in step #7.<br>
<img src="https://alexanderdevelopment.net/content/images/2017/09/chrome_2017-09-11_13-24-50.png#img-thumbnail" alt="Running Dynamics 365 Configuration Data Mover jobs in VSTS builds"></li>
<li>Set the arguments to include the relative path to your job configuration file. For this example, it is <em>-c ....\data\alm-test-import.xml</em><br>
<img src="https://alexanderdevelopment.net/content/images/2017/09/chrome_2017-09-11_12-46-23.png#img-thumbnail" alt="Running Dynamics 365 Configuration Data Mover jobs in VSTS builds"></li>
<li><em>(This step is only required if you are not saving the connection parameters in the job file.)</em> Add source and target arguments, too. The source argument is -s, and the target argument is -t. The values will look just like the source/target attributes from a job configuration file where you have saved the values.</li>
<li>Set the working folder value to the directory that contains the AlexanderDevelopment.ConfigDataMover.Cli.exe assembly. You can see that setting in the screenshot above.</li>
</ol>
<p>At this point you should be able to save and queue the build. Assuming everything is set up properly, you should get a nice result like this:<br>
<img src="https://alexanderdevelopment.net/content/images/2017/09/chrome_2017-09-11_12-49-49.png#img-thumbnail" alt="Running Dynamics 365 Configuration Data Mover jobs in VSTS builds"></p>
<p>If you do get an error, it's probably something simple like the paths not being set correctly, and a quick review of the output logs should point to the solution.</p>
<p>That's all there is to it. Are you using automated builds in VSTS for your Dynamics 365 projects? Do see value in managing configuration data like this? Share your thoughts in the comments!</p>
</div>]]></content:encoded></item><item><title><![CDATA[Unit testing Microsoft Dynamics CRM code]]></title><description><![CDATA[<div class="kg-card-markdown"><p>If you're developing code that runs against Dynamics CRM, you know you should be testing it, right? As a developer first and foremost, I always believed that tests and documentation got in the way of the important - and more fun - stuff, but as I transitioned into a management</p></div>]]></description><link>https://alexanderdevelopment.net/post/2011/03/31/unit-testing-microsoft-dynamics-crm-code/</link><guid isPermaLink="false">5a5837216636a30001b976a5</guid><category><![CDATA[Microsoft Dynamics CRM]]></category><category><![CDATA[unit testing]]></category><category><![CDATA[CRM 4]]></category><category><![CDATA[continuous integration]]></category><dc:creator><![CDATA[Lucas Alexander]]></dc:creator><pubDate>Fri, 01 Apr 2011 00:00:00 GMT</pubDate><content:encoded><![CDATA[<div class="kg-card-markdown"><p>If you're developing code that runs against Dynamics CRM, you know you should be testing it, right? As a developer first and foremost, I always believed that tests and documentation got in the way of the important - and more fun - stuff, but as I transitioned into a management role with responsibility for my company's Dynamics CRM system, I began to appreciate the value of the less-fun stuff.In this post I'll give you an overview of our continuous integration environment and offer a conceptual example of how to unit test your CRM code without having to execute tests against a running CRM system.Our full build and unit testing process used the following:</p>
<ol>
<li>
<p><a href="http://nant.sourceforge.net/">NAnt</a> for builds</p>
</li>
<li>
<p><a href="http://nunit.org/">NUnit</a> for unit tests</p>
</li>
<li>
<p><a href="http://subversion.apache.org/">Subversion</a> (SVN) for version control</p>
</li>
<li>
<p><a href="http://confluence.public.thoughtworks.org/display/CCNET/Welcome+to+CruiseControl.NET">CruiseControl.NET</a> (CC.NET) for continuous integration</p>
</li>
<li>
<p><a href="http://ayende.com/projects/rhino-mocks.aspx">Rhino.Mocks</a> for mock object framework</p>
</li>
</ol>
<p>Whenever a developer made a commit to SVN, CC.NET would execute the correct NAnt build target (different ones for production, testing, etc.), then it would run the NUnit tests. The results of the build (broken/successful) and the results of the NUnit tests were all reported through the CC.NET web interface so you could see a historical view. CC.NET also has a desktop notification app that is green when all builds are good or red when all builds are bad that you can use to easily check up on your development team.</p>
<p>Originally our NUnit tests ran against our CRM staging server and staging database, but we found that it was a problem keeping the staging system populated with &quot;real&quot; data, and our staging system was underpowered, so unit tests took a long time to execute. We solved this by using Rhino.Mocks to setup a mock CRM framework to verify that our code would send the correct calls to CRM without actually having to make the calls against an actual system.</p>
<p>Here's a conceptual example from version 4, but it will work similarly in 2011. Let's say we want to test code that deactivates an account. First, the test method sets up a mock object to represent the CRM service. Second, we set up an object to retrieve the setstate request object that the production code will pass to CRM. Third, the test method runs the production code against the mocked CRM service and captures the request object. Finally, we test the properties of the request object using an Assert.AreEqual call.</p>
<p>If you're ready to dig into the technical details of Rhino.Mocks + CRM, take a look at this excellent blog post with code samples: <a href="http://www.develop1.net/public/post/Unit-Testing-Dynamics-CRM2011-Pipeline-Plugins-using-Rhino-Mocks.aspx">http://www.develop1.net/public/post/Unit-Testing-Dynamics-CRM2011-Pipeline-Plugins-using-Rhino-Mocks.aspx</a>.</p>
</div>]]></content:encoded></item></channel></rss>