[TestFixture]
public class SettingsBaseTest
{
+#if TARGET_JVM
+ class CustomerException : Exception { }
+#endif
class MySettings : SettingsBase
{
[UserScopedSetting] // ignored in non-ApplicationSettingsBase
try {
Assert.AreEqual (100, s.Foo, "#1");
Assert.Fail ("#2");
+#if !TARGET_JVM
} catch (Win32Exception) {
+#else
+ } catch (CustomerException) {
+#endif
}
}
{
public override SettingsPropertyValueCollection GetPropertyValues (SettingsContext context, SettingsPropertyCollection props)
{
+#if !TARGET_JVM
throw new Win32Exception (); // unlikely thrown otherwise.
+#else
+ throw new CustomerException (); // unlikely thrown otherwise.
+#endif
}
}