TestStack / TestStack.Seleno

Seleno helps you write automated UI tests in the right way by implementing Page Objects and Page Components and by reading from and writing to web pages using strongly typed view models.
http://teststack.github.com/TestStack.Seleno/
MIT License
180 stars 60 forks source link

Relative path passed to ProjectLocation.FromPath can cause silent IIS express failures #227

Open jacku-abide opened 8 years ago

jacku-abide commented 8 years ago

After many hours debugging a problem where I was getting a 404 for my IIS express site when using the following code to setup the project location:

ProjectLocation.FromPath("MyProject.GUI")

I have come to the conclusion that relative paths should not be allowed to be passed to this method, or at the very least they need to be converted to absolute paths before being passed to IIS Express command line (and then on to iisexpress.exe via the generated applicationhost.config).

The reason being that IIS appears not to support relative paths for the virtualDirectory physicalPath setting, which is ultimately where the "MyProject.GUI" string is getting passed to. It returns a 404 in some instances, or may not work at all. But it gives no obvious errors when spun up.

robdmoore commented 8 years ago

This is great - thanks for the call out!

Do you have any time to create a PR to protect the code in Seleno from this problem?