Running and Testing from VS2010

Oct 6, 2010 at 1:49 AM
Edited Oct 6, 2010 at 4:57 AM

I have successfully downloaded the code and got it to load within Visual Studio 2010. I have managed to get the WCF running from VS in console mode. I can browse to the service http://ARIES/ps/memory and get the help pages (although it does state "Endpoint not found" - don't know if that is relevant). When I run up the Silverlight Test (got the ClientAccessPolicy file in the right place, tweaked a couple of lines to look at ARIES instead of localhost) it passes the A1 test for ClientAccessPolicy but the A2 LaharRunning test fails - correctly after timeout time when not running but really quickly (192ms) when it is running with the same error saying "not running".

However, when I run the Laharsub.Client.Net.Test - all tests pass and data appears on the console.

Any idea how I can find out why the Silverlight tests want respond correctly to the calls or some pointers on how to set it up to run from VS 2010?

Oct 7, 2010 at 9:44 PM

I think I have isolated the reason why the Silverlight test is failing. The clientaccesspolicy.xml is not in the correct place. It needs to be where the WCF is running - i.e. in this case Http://ARIES/... - however, how on earth do I do that when not running IIS but using VS 2010?

Oct 8, 2010 at 5:03 AM
Edited Oct 8, 2010 at 5:03 AM

Rich, unfortunately you cannot use the web server built into VS 2010 to expose clientaccesspolicy.xml file at the root of the domain name while the Laharsub server is running (at the same port). This is because VS attempts to gain the exclusive registration of the same port number for which Laharsub service already has secured partial registration, which causes a conflict. 

One convenient way to expose the clientaccesspolicy.xml file at the same port number which the Laharsub service is using without using IIS is to write a small standalone WCF service to expose it, as described at Just make sure to use the same port number for exposing the clientaccesspolicy.xml file as the one Laharsub service is configured to use (by default 80). 

Just for completeness, the easiest way to expose the clientaccesspolicy.xml file is really to drop it right into the document root of IIS (typically at c:\inetpub\wwwroot). Is there any particular reason you cannot use IIS in your case?

Oct 10, 2010 at 9:14 PM

Thanks for the feedback.

My local dev environment doesn't currently have IIS installed - looks like this may be the best situation and is something I need to considering for other devs when working outside the inhouse environment.

Thanks again.