Browse Source

Prevented a crash in the tests on Mono because of a Mono bug.

Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
pull/520/head
Dimitar Dobrev 10 years ago
parent
commit
e73f490f89
  1. 12
      tests/CSharpTemp/CSharpTemp.Tests.cs

12
tests/CSharpTemp/CSharpTemp.Tests.cs

@ -27,9 +27,17 @@ public class CSharpTempTests : GeneratorTestFixture @@ -27,9 +27,17 @@ public class CSharpTempTests : GeneratorTestFixture
var isNoParams = foo.IsNoParams;
foo.SetNoParams();
}
using (var qux = new Qux())
// TODO: remove when the bug in question is fixed
if (Type.GetType("Mono.Runtime") != null)
{
new Bar(qux).Dispose();
Assert.Fail("Crashes with Mono because of a problem with marshalling arrays: https://gist.github.com/tritao/7e62c71ffe57d6bc326e");
}
else
{
using (var qux = new Qux())
{
new Bar(qux).Dispose();
}
}
}

Loading…
Cancel
Save