Imported Upstream version 6.4.0.137

Former-commit-id: 943baa9f16a098c33e129777827f3a9d20da00d6
This commit is contained in:
Xamarin Public Jenkins (auto-signing)
2019-07-26 19:53:28 +00:00
parent e9207cf623
commit ef583813eb
2712 changed files with 74169 additions and 40587 deletions

View File

@@ -739,7 +739,7 @@ namespace MonoTests.System.Web.UI
Assert.AreEqual ("NunitWeb/MyPage.aspx", ctrl.ResolveClientUrl ("NunitWeb/MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual ("NunitWeb/../MyPage.aspx", ctrl.ResolveClientUrl ("NunitWeb/../MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual ("NunitWeb/./MyPage.aspx", ctrl.ResolveClientUrl ("NunitWeb/./MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual ("http://google.com/", ctrl.ResolveClientUrl ("http://google.com/"), "ResolveClientUrl Failed");
Assert.AreEqual ("http://example.com/", ctrl.ResolveClientUrl ("http://example.com/"), "ResolveClientUrl Failed");
Assert.AreEqual ("MyPage.aspx?param=val&yes=no", ctrl.ResolveClientUrl ("~/MyPage.aspx?param=val&yes=no"), "~/../MyPage.aspx");
Assert.AreEqual ("../MyPage.aspx?param=val&yes=no", ctrl.ResolveClientUrl ("~/../MyPage.aspx?param=val&yes=no"), "~/../MyPage.aspx");
@@ -784,7 +784,7 @@ namespace MonoTests.System.Web.UI
Assert.AreEqual ("Folder/NunitWeb/MyPage.aspx", ctrl.ResolveClientUrl ("NunitWeb/MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual ("Folder/MyPage.aspx", ctrl.ResolveClientUrl ("NunitWeb/../MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual ("Folder/NunitWeb/MyPage.aspx", ctrl.ResolveClientUrl ("NunitWeb/./MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual ("http://google.com/", ctrl.ResolveClientUrl ("http://google.com/"), "ResolveClientUrl Failed");
Assert.AreEqual ("http://example.com/", ctrl.ResolveClientUrl ("http://example.com/"), "ResolveClientUrl Failed");
Assert.AreEqual ("MyPage.aspx?param=val&yes=no", ctrl.ResolveClientUrl ("~/MyPage.aspx?param=val&yes=no"), "~/../MyPage.aspx");
Assert.AreEqual ("../MyPage.aspx?param=val&yes=no", ctrl.ResolveClientUrl ("~/../MyPage.aspx?param=val&yes=no"), "~/../MyPage.aspx");
@@ -825,7 +825,7 @@ namespace MonoTests.System.Web.UI
Assert.AreEqual (appPath + "/NunitWeb/MyPage.aspx", ctrl.ResolveUrl ("NunitWeb/MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual (appPath + "/MyPage.aspx", ctrl.ResolveUrl ("NunitWeb/../MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual (appPath + "/NunitWeb/MyPage.aspx", ctrl.ResolveUrl ("NunitWeb/./MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual ("http://google.com/", ctrl.ResolveUrl ("http://google.com/"), "ResolveClientUrl Failed");
Assert.AreEqual ("http://example.com/", ctrl.ResolveUrl ("http://example.com/"), "ResolveClientUrl Failed");
Assert.AreEqual (appPath + "/MyPage.aspx?param=val&yes=no", ctrl.ResolveUrl ("~/MyPage.aspx?param=val&yes=no"), "~/../MyPage.aspx");
Assert.AreEqual ("/MyPage.aspx?param=val&yes=no", ctrl.ResolveUrl ("~/../MyPage.aspx?param=val&yes=no"), "~/../MyPage.aspx");
@@ -872,7 +872,7 @@ namespace MonoTests.System.Web.UI
Assert.AreEqual (appPath + "/Folder/NunitWeb/MyPage.aspx", ctrl.ResolveUrl ("NunitWeb/MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual (appPath + "/Folder/MyPage.aspx", ctrl.ResolveUrl ("NunitWeb/../MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual (appPath + "/Folder/NunitWeb/MyPage.aspx", ctrl.ResolveUrl ("NunitWeb/./MyPage.aspx"), "ResolveClientUrl Failed");
Assert.AreEqual ("http://google.com/", ctrl.ResolveUrl ("http://google.com/"), "ResolveClientUrl Failed");
Assert.AreEqual ("http://example.com/", ctrl.ResolveUrl ("http://example.com/"), "ResolveClientUrl Failed");
Assert.AreEqual (appPath + "/MyPage.aspx?param=val&yes=no", ctrl.ResolveUrl ("~/MyPage.aspx?param=val&yes=no"), "~/../MyPage.aspx");
Assert.AreEqual ("/MyPage.aspx?param=val&yes=no", ctrl.ResolveUrl ("~/../MyPage.aspx?param=val&yes=no"), "~/../MyPage.aspx");

View File

@@ -50,8 +50,8 @@ namespace MonoTests.System.Web.UI
public void CssStyleCollection_BackgroundImage () {
WebControl c = new WebControl (HtmlTextWriterTag.A);
CssStyleCollection css = c.Style;
string url = "http://www.go-mono.com/space here?key1=val1&key2=val2";
string url_encoded = "http://www.go-mono.com/space%20here?key1=val1&key2=val2";
string url = "http://www.example.com/space here?key1=val1&key2=val2";
string url_encoded = "http://www.example.com/space%20here?key1=val1&key2=val2";
css.Add (HtmlTextWriterStyle.BackgroundImage, url);
@@ -64,8 +64,8 @@ namespace MonoTests.System.Web.UI
public void CssStyleCollection_BackgroundImage2 () {
WebControl c = new WebControl (HtmlTextWriterTag.A);
CssStyleCollection css = c.Style;
string url = "http://www.go-mono.com/space here?key1=val1&key2=val2";
string url_encoded = "http://www.go-mono.com/space%20here?key1=val1&key2=val2";
string url = "http://www.example.com/space here?key1=val1&key2=val2";
string url_encoded = "http://www.example.com/space%20here?key1=val1&key2=val2";
css.Add ("background-image", url);
@@ -78,8 +78,8 @@ namespace MonoTests.System.Web.UI
public void CssStyleCollection_BackgroundImage3 () {
WebControl c = new WebControl (HtmlTextWriterTag.A);
CssStyleCollection css = c.Style;
string url = "http://www.go-mono.com/space here?key1=val1&key2=val2";
string url_encoded = "http://www.go-mono.com/space%20here?key1=val1&key2=val2";
string url = "http://www.example.com/space here?key1=val1&key2=val2";
string url_encoded = "http://www.example.com/space%20here?key1=val1&key2=val2";
css.Add ("background-image", "url(" + url_encoded + ")");
@@ -92,8 +92,8 @@ namespace MonoTests.System.Web.UI
public void CssStyleCollection_BackgroundImage4 () {
WebControl c = new WebControl (HtmlTextWriterTag.A);
CssStyleCollection css = c.Style;
string url = "http://www.go-mono.com/space here?key1=val1&key2=val2";
string url_encoded = "http://www.go-mono.com/space%20here?key1=val1&key2=val2";
string url = "http://www.example.com/space here?key1=val1&key2=val2";
string url_encoded = "http://www.example.com/space%20here?key1=val1&key2=val2";
c.Attributes ["style"] = "background-image:url(" + url_encoded + ");";

View File

@@ -170,10 +170,10 @@ namespace MonoTests.System.Web.UI {
[Test]
public void EscapeUrl ()
{
w.AddAttribute (HtwAttribute.Href, "http://www.google.com/search?hl=en&q=i+love+nunit&btnG=Google+Search");
w.AddAttribute (HtwAttribute.Href, "http://www.example.com/search?hl=en&q=i+love+nunit&btnG=Google+Search");
w.RenderBeginTag (HtwTag.A);
w.RenderEndTag ();
Assert.AreEqual ("<a href=\"http://www.google.com/search?hl=en&amp;q=i+love+nunit&amp;btnG=Google+Search\"></a>", sw.ToString ());
Assert.AreEqual ("<a href=\"http://www.example.com/search?hl=en&amp;q=i+love+nunit&amp;btnG=Google+Search\"></a>", sw.ToString ());
}
// Which attrs fall here
@@ -377,11 +377,11 @@ namespace MonoTests.System.Web.UI {
[Test]
public void AddStyleAttribute1 ()
{
w.AddStyleAttribute (HtmlTextWriterStyle.BackgroundImage, "http://www.go-mono.com/");
w.AddStyleAttribute (HtmlTextWriterStyle.BackgroundImage, "http://www.example.com/");
w.RenderBeginTag ("div");
w.RenderEndTag ();
Assert.AreEqual ("<div style=\"background-image:url(http://www.go-mono.com/);\">\n\n</div>", sw.ToString ());
Assert.AreEqual ("<div style=\"background-image:url(http://www.example.com/);\">\n\n</div>", sw.ToString ());
}
[Test]