Imported Upstream version 4.3.2.467

Former-commit-id: 9c2cb47f45fa221e661ab616387c9cda183f283d
This commit is contained in:
Xamarin Public Jenkins
2016-02-22 11:00:01 -05:00
parent f302175246
commit f3e3aab35a
4097 changed files with 122406 additions and 82300 deletions

View File

@ -44,9 +44,7 @@ using MonoTests.Common;
using System.Web.UI.Adapters;
#if NET_4_0
using System.Web.Routing;
#endif
namespace MonoTests.System.Web.UI
{
@ -973,11 +971,7 @@ namespace MonoTests.System.Web.UI
fr.Controls ["__EVENTTARGET"].Value = "container$children$lb";
fr.Controls ["__EVENTARGUMENT"].Value = String.Empty;
t.Request = fr;
#if NET_4_0
string originalHtml = "<span id=\"container\"><a id=\"container_children_lb\" href=\"javascript:__doPostBack(&#39;container$children$lb&#39;,&#39;&#39;)\">Woot! I got clicked!</a></span><hr/>";
#else
string originalHtml = @"<span id=""container""><a href=""javascript:__doPostBack('container$children$lb','')"" id=""container_children_lb"">Woot! I got clicked!</a></span><hr/>";
#endif
string pageHtml = t.Run ();
string renderedHtml = HtmlDiff.GetControlFromPageHtml (pageHtml);
@ -998,7 +992,6 @@ namespace MonoTests.System.Web.UI
WebTest.CopyResource (GetType (), "OverridenControlsPropertyAndPostBack_Bug594238.aspx", "OverridenControlsPropertyAndPostBack_Bug594238.aspx");
}
#if NET_4_0
[Test]
public void GetRouteUrl_Object ()
{
@ -1116,7 +1109,6 @@ namespace MonoTests.System.Web.UI
path = ctl.GetRouteUrl (String.Empty, (RouteValueDictionary) null);
Assert.IsNull (path, "#A3-3");
}
#endif
#region helpcalsses
class ControlWithState : Control
{

View File

@ -23,7 +23,6 @@
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
#if NET_4_0
using System;
using System.Web.UI;
@ -60,4 +59,3 @@ namespace MonoTests.System.Web.UI
}
}
}
#endif

View File

@ -81,13 +81,8 @@ namespace MonoTests.System.Web.UI
byte [] data = Convert.FromBase64String (expected);
byte [] signed_data = Convert.FromBase64String (signed);
Assert.IsTrue (BitConverter.ToString (signed_data).StartsWith (BitConverter.ToString (data)), "4 / same data");
#if NET_4_0
// 32 bytes == 256 bits -> match HMACSHA256 as default
Assert.AreEqual (32, signed_data.Length - data.Length, "signature length");
#else
// 20 bytes == 160 bits -> match HMACSHA1 as default
Assert.AreEqual (20, signed_data.Length - data.Length, "signature length");
#endif
}
[Test]
@ -114,13 +109,8 @@ namespace MonoTests.System.Web.UI
byte [] data = Convert.FromBase64String (expected);
byte [] signed_data = Convert.FromBase64String (signed);
Assert.IsTrue (BitConverter.ToString (signed_data).StartsWith (BitConverter.ToString (data)), "5 / same data");
#if NET_4_0
// 32 bytes == 256 bits -> match HMACSHA256 as default
Assert.AreEqual (32, signed_data.Length - data.Length, "signature length");
#else
// 20 bytes == 160 bits -> match HMACSHA1 as default
Assert.AreEqual (20, signed_data.Length - data.Length, "signature length");
#endif
LosFormatter lf6 = new LosFormatter (true, "string"); // bug #649551
signed = NoKeyRoundTrip (lf6, "true, plain");
Assert.AreNotEqual (expected, signed, "6");
@ -171,7 +161,6 @@ namespace MonoTests.System.Web.UI
Assert.AreNotEqual (r4, r5, "r4-r5");
}
#if NET_4_0
[Test]
[ExpectedException (typeof (NotSupportedException))]
public void Deserialize_Stream_NonSeekable ()
@ -181,19 +170,6 @@ namespace MonoTests.System.Web.UI
LosFormatter lf = new LosFormatter ();
lf.Serialize (ns, s1);
}
#else
[Test] // bug #411115
public void Deserialize_Stream_NonSeekable ()
{
string s1 = "Hello world";
NonSeekableStream ns = new NonSeekableStream ();
LosFormatter lf = new LosFormatter ();
lf.Serialize (ns, s1);
ns.Reset ();
string s2 = lf.Deserialize (ns) as string;
Assert.AreEqual (s1, s2);
}
#endif
[Test] // bug #324526
public void Serialize ()
{