summaryrefslogtreecommitdiffstats
path: root/src/DotNetOpenAuth.Test/Hosting/HostingTests.cs
diff options
context:
space:
mode:
authorAndrew Arnott <andrewarnott@gmail.com>2009-08-31 22:20:01 -0700
committerAndrew Arnott <andrewarnott@gmail.com>2009-08-31 22:20:01 -0700
commit0488ebcfaef60e51bfcf7958b4a59d0ba5332a0f (patch)
treea6681a912fab62ccf5e8e005ac382f6bcfb34a4b /src/DotNetOpenAuth.Test/Hosting/HostingTests.cs
parent0918f556a7da5f731b97cb4bbaa1ee5349c29d41 (diff)
parent307ba2d4b5ad4574a52922b40027ea978e3d8a04 (diff)
downloadDotNetOpenAuth-0488ebcfaef60e51bfcf7958b4a59d0ba5332a0f.zip
DotNetOpenAuth-0488ebcfaef60e51bfcf7958b4a59d0ba5332a0f.tar.gz
DotNetOpenAuth-0488ebcfaef60e51bfcf7958b4a59d0ba5332a0f.tar.bz2
Merge branch 'v3.0' into v3.1
Conflicts: src/DotNetOpenAuth.vsmdi src/DotNetOpenAuth/OpenId/OpenIdStrings.Designer.cs src/DotNetOpenAuth/OpenId/OpenIdStrings.resx
Diffstat (limited to 'src/DotNetOpenAuth.Test/Hosting/HostingTests.cs')
-rw-r--r--src/DotNetOpenAuth.Test/Hosting/HostingTests.cs18
1 files changed, 11 insertions, 7 deletions
diff --git a/src/DotNetOpenAuth.Test/Hosting/HostingTests.cs b/src/DotNetOpenAuth.Test/Hosting/HostingTests.cs
index ff72c66..d7de7a1 100644
--- a/src/DotNetOpenAuth.Test/Hosting/HostingTests.cs
+++ b/src/DotNetOpenAuth.Test/Hosting/HostingTests.cs
@@ -18,15 +18,19 @@ namespace DotNetOpenAuth.Test.Hosting {
public class HostingTests : TestBase {
[TestMethod]
public void AspHostBasicTest() {
- using (AspNetHost host = AspNetHost.CreateHost(TestWebDirectory)) {
- HttpWebRequest request = (HttpWebRequest)WebRequest.Create(host.BaseUri);
- using (HttpWebResponse response = (HttpWebResponse)request.GetResponse()) {
- Assert.AreEqual(HttpStatusCode.OK, response.StatusCode);
- using (StreamReader sr = new StreamReader(response.GetResponseStream())) {
- string content = sr.ReadToEnd();
- StringAssert.Contains(content, "Test home page");
+ try {
+ using (AspNetHost host = AspNetHost.CreateHost(TestWebDirectory)) {
+ HttpWebRequest request = (HttpWebRequest)WebRequest.Create(host.BaseUri);
+ using (HttpWebResponse response = (HttpWebResponse)request.GetResponse()) {
+ Assert.AreEqual(HttpStatusCode.OK, response.StatusCode);
+ using (StreamReader sr = new StreamReader(response.GetResponseStream())) {
+ string content = sr.ReadToEnd();
+ StringAssert.Contains(content, "Test home page");
+ }
}
}
+ } catch (FileNotFoundException ex) {
+ Assert.Inconclusive("Unable to execute hosted ASP.NET tests because {0} could not be found. {1}", ex.FileName, ex.FusionLog);
}
}
}