21
votes

I'm involved in developing a sandboxed Microsoft Dynamics CRM 2011 Online plugin and have a set of tests that I can drive from a xUnit front end on my local machine given that I right-click the Package and select the Deploy option (and resort to using the plugin loader sample when that doesn't work).

I'd like to be able to automate the running of my tests on my CI rig, where I'll need it to upload a fresh binary as part of each run.

We've looked at http://pluginregcrm2011.codeplex.com/ but it has bugs that prevent it working for Online and in short looks like it's no longer being maintained and I'm not keen to take ownership of what should be a fundamental tool that a platform/ecosystem should just have.

Is anyone using that tool or another plugin uploader non-interactively? Am I missing something?

2
Have you looked at the source of the plugin registration code? You should definitely be able to tap into what it does.Peter Majeed
I know, it's only code and it can all be fixed - I was just hoping that a non-trivial dev platform that competes with other serious platforms might have an automated deploy story that doesnt involve me hacking about in the MS (or dev=rived works) sample-grade code. Is that really too much to expect - not in my world hence the question...Ruben Bartelink
BTW a 200 pt bounty on this expired with no answers. A bit of a sad state of affairs...Ruben Bartelink

2 Answers

3
votes

I know I'm late with my answer and I`m pretty sure that you already have found a solution which is working for you.

However I felt the same pain and I have hacked a small application which could be used to simply update the plugin assembly, without doing any configuration work.

PluginAssemblyLoader -f "C:\MyPlugin.dll" -c "Url=http://crmserver/org;"

Please see http://msdyncrm-contrib.github.io/PluginAssemblyLoader

2
votes

There isn't an easy OOB experience with this but the CRM 2011 Developer Toolkit just uses a set of MSBuild targets that you can call yourself. It's just MSBuild, so you could hook it into your CI build if required. If you install or just extract the Developer Toolkit MSI in the SDK you'll find the following two files in there...

Microsoft.CrmdeveloperTools.CrmClient.dll
Microsoft.CrmdeveloperTools.CrmClient.targets

As an aside it would be nice if MS would open source this as the current implementation uses predominantly sealed and internal classes within the custom tasks.