From 9ee88990b81155a547c91f7a345f32de7cb590ca Mon Sep 17 00:00:00 2001 From: Sebastien Ros Date: Mon, 20 Feb 2012 11:29:40 -0800 Subject: [PATCH] Fixing specflow tests host --HG-- branch : 1.x --- src/Orchard.Specs/Hosting/WebHost.cs | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/src/Orchard.Specs/Hosting/WebHost.cs b/src/Orchard.Specs/Hosting/WebHost.cs index b0a4e5265..eae2a4367 100644 --- a/src/Orchard.Specs/Hosting/WebHost.cs +++ b/src/Orchard.Specs/Hosting/WebHost.cs @@ -37,12 +37,17 @@ namespace Orchard.Specs.Hosting { catch { } // Trying the two known relative paths to the Orchard.Web directory. // The second one is for the target "spec" in orchard.proj. - if (ConfigurationManager.AppSettings["orchardHosting"] != null) { - _orchardWebPath = baseDir.Combine(ConfigurationManager.AppSettings["orchardHosting"]); - } - else { - _orchardWebPath = baseDir.Up(3).Combine("Orchard.Web"); + //if (ConfigurationManager.AppSettings["orchardHosting"] != null) { + // _orchardWebPath = baseDir.Combine(ConfigurationManager.AppSettings["orchardHosting"]); + //} + //else { + for (int i = 1; i < 10; i++) { + _orchardWebPath = baseDir.Up(i).Combine("Orchard.Web"); + if (_orchardWebPath.Exists) { + break; + } } + //} if (!_orchardWebPath.Exists) { _orchardWebPath = baseDir.Parent.Combine("stage");