Permalink
Browse files

Fixed some whitespace garbage

  • Loading branch information...
1 parent 90bb2f1 commit 7c51db84d09976def9ec1d17acca4b84fd32ccce @pruiz committed Dec 16, 2012
@@ -64,37 +64,37 @@ protected override string GetComponents(Uri uri, UriComponents components, UriFo
builder.Length == 0)
start++;
- if (start > 0) builder.Append(s, start, end - start);
+ if (start > 0) builder.Append(s, start, end - start);
}
if ((components & UriComponents.Query) == UriComponents.Query)
{
int index = s.IndexOf('?');
- if (index != -1)
- {
- if ((components & UriComponents.KeepDelimiter) != UriComponents.KeepDelimiter &&
- builder.Length == 0)
- index++;
+ if (index != -1)
+ {
+ if ((components & UriComponents.KeepDelimiter) != UriComponents.KeepDelimiter &&
+ builder.Length == 0)
+ index++;
- int fragIndex = s.IndexOf('#');
- int end = fragIndex == -1 ? s.Length : fragIndex;
- builder.Append(s, index, end - index);
- }
+ int fragIndex = s.IndexOf('#');
+ int end = fragIndex == -1 ? s.Length : fragIndex;
+ builder.Append(s, index, end - index);
+ }
}
if ((components & UriComponents.Fragment) == UriComponents.Fragment)
{
int index = s.IndexOf('#');
- if (index != -1)
- {
- if ((components & UriComponents.KeepDelimiter) != UriComponents.KeepDelimiter &&
- builder.Length == 0)
- index++;
+ if (index != -1)
+ {
+ if ((components & UriComponents.KeepDelimiter) != UriComponents.KeepDelimiter &&
+ builder.Length == 0)
+ index++;
- builder.Append(s, index, s.Length - index);
- }
+ builder.Append(s, index, s.Length - index);
+ }
}
return builder.ToString();
@@ -52,23 +52,23 @@ public void CompareInvalidTest ()
}
[Test]
- [Category("NotWorking")]
+ [Category("NotWorking")]
[ExpectedException (typeof (ArgumentException))]
public void NonPackUriCompareTest ()
{
PackUriHelper.ComparePackUri (new Uri ("http://wtest.com"), a);
}
[Test]
- [Category("NotWorking")]
+ [Category("NotWorking")]
[ExpectedException (typeof (ArgumentException))]
public void NonPackUriCompareRelativeTest ()
{
PackUriHelper.ComparePackUri (new Uri ("wtest.com", UriKind.Relative), a);
}
[Test]
- [Category("NotWorking")]
+ [Category("NotWorking")]
[ExpectedException (typeof (ArgumentException))]
public void InvalidPartUriCompareTest ()
{
@@ -98,12 +98,12 @@ public void CreateTest ()
new Uri ("/main.html", UriKind.Relative), "#frag").ToString (), "#3");
}
- [Test]
- public void CreateTest2()
- {
- Uri uri = PackUriHelper.Create(new Uri("http://www.test.com/pack1.pkg"));
- Assert.AreEqual("pack://pack:,,http:%2C%2Cwww.test.com%2Cpack1.pkg,/", PackUriHelper.Create(uri).ToString());
- }
+ [Test]
+ public void CreateTest2()
+ {
+ Uri uri = PackUriHelper.Create(new Uri("http://www.test.com/pack1.pkg"));
+ Assert.AreEqual("pack://pack:,,http:%2C%2Cwww.test.com%2Cpack1.pkg,/", PackUriHelper.Create(uri).ToString());
+ }
[Test]
[ExpectedException (typeof (ArgumentException))]
@@ -196,13 +196,13 @@ public void GetPackageUri3 ()
[Category("NotWorking")]
public void GetPartUriTest ()
{
- var pack = PackUriHelper.Create(new Uri("http://www.test.com/pack1.pkg"));
- var part = new Uri("/main.html", UriKind.Relative);
- var pack_part = new Uri(@"pack://pack:,,http:%2C%2Cwww.test.com%2Cpack1.pkg,/main.html");
+ var pack = PackUriHelper.Create(new Uri("http://www.test.com/pack1.pkg"));
+ var part = new Uri("/main.html", UriKind.Relative);
+ var pack_part = new Uri(@"pack://pack:,,http:%2C%2Cwww.test.com%2Cpack1.pkg,/main.html");
- Assert.IsNull(PackUriHelper.GetPartUri(pack), "#1");
- Assert.AreEqual(pack_part, PackUriHelper.Create(pack, part), "#2");
- Assert.AreEqual(part, PackUriHelper.GetPartUri(PackUriHelper.Create(pack, part)), "#3");
+ Assert.IsNull(PackUriHelper.GetPartUri(pack), "#1");
+ Assert.AreEqual(pack_part, PackUriHelper.Create(pack, part), "#2");
+ Assert.AreEqual(part, PackUriHelper.GetPartUri(PackUriHelper.Create(pack, part)), "#3");
}
[Test]

0 comments on commit 7c51db8

Please sign in to comment.