Imported Upstream version 5.16.0.100

Former-commit-id: 38faa55fb9669e35e7d8448b15c25dc447f25767
This commit is contained in:
Xamarin Public Jenkins (auto-signing)
2018-08-07 15:19:03 +00:00
parent 0a9828183b
commit 7d7f676260
4419 changed files with 170950 additions and 90273 deletions

View File

@@ -121,7 +121,23 @@ namespace MonoTests.System.IO.Packaging {
Assert.AreEqual (package, part.Package, "Wrong package3");
Assert.AreEqual ("/third", part.Uri.ToString (), "Wrong package selected3");
}
[Test]
public void CheckPartExtensions ()
{
package.CreatePart (new Uri ("/first", UriKind.Relative), "my/a");
package.CreatePart (new Uri ("/second", UriKind.Relative), "my/b", CompressionOption.Maximum);
package.CreatePart (new Uri ("/third", UriKind.Relative), "test/c", CompressionOption.SuperFast);
package.CreatePart (new Uri ("/fourth.txt", UriKind.Relative), "test/d");
package.Close ();
using (var archive = new global::System.IO.Compression.ZipArchive (stream, global::System.IO.Compression.ZipArchiveMode.Read)) {
var contentTypes = archive.GetEntry ("[Content_Types].xml");
var reader = new StreamReader (contentTypes.Open ());
var expected = "<?xml version=\"1.0\"?><Types xmlns=\"http://schemas.openxmlformats.org/package/2006/content-types\"><Override ContentType=\"my/a\" PartName=\"/first\" /><Override ContentType=\"my/b\" PartName=\"/second\" /><Override ContentType=\"test/c\" PartName=\"/third\" /><Default ContentType=\"test/d\" Extension=\"txt\" /></Types>";
Assert.AreEqual (expected, reader.ReadToEnd ());
}
}
[Test]
public void SameExtensionDifferentContentTypeTest ()
{

View File

@@ -63,15 +63,15 @@ namespace MonoTests.System.Windows {
protected override void Merge (PropertyMetadata baseMetadata, DependencyProperty dp)
{
Console.WriteLine (Environment.StackTrace);
// Console.WriteLine (Environment.StackTrace);
base.Merge (baseMetadata, dp);
}
protected override void OnApply (DependencyProperty dp, Type targetType)
{
base.OnApply (dp, targetType);
Console.WriteLine ("IsSealed in OnApply? {0}", IsSealed);
Console.WriteLine (Environment.StackTrace);
// Console.WriteLine ("IsSealed in OnApply? {0}", IsSealed);
// Console.WriteLine (Environment.StackTrace);
}
}