I following this procedure provided by Microsoft, topic
Setting up an In-App purchase mock service by using IIS,
to setup the mock service. Then, i try to access it through the application try using CurrentApp.RequestProductPurchaseAsync("MyProduct", false)
. The application gets 805a0194 error code.
I can find interaction with the site by looking at the IIS log. Also, stooping the site causes the App to get a can't connect message instead, so it is not an network problem.
My App was running on windows phone 8.1 simulator of visual studio 2015.
After several hours looking were did i get wrong, i realize the problem is mock service itself. The url requests generated from the emulator are pointing to v9 virtual path instead of v8 virtual path. Can be see on IIS logs.
To adjust the mock service to the new v9 path, edit the global.asax.cs and replace the line
RouteTable.Routes.Add(new ServiceRoute("v8", new WebServiceHostFactory(), typeof(IapMockBrowseService)));
by
RouteTable.Routes.Add(new ServiceRoute("v9", new WebServiceHostFactory(), typeof(IapMockBrowseService)));
Then build and deploy using visual studio publish feature.
This fix may only be needed for 8.1 simulators, i didn't test on others.
Other problem is the deploy of the mock service. Running the command CatalogServiceMockDeploymentPackage.deploy.cmd /Y
as is in the procedure it installs the files at the site subfolder CatalogMockService
instead of installing it on the root of the site. The site folder should look like this:
Probably something in the deploy tool also changed since the package it was publish. To fix simple move the files on folder up to match the print screen. If the site was deployed again with visual studio it should be already fine.