-Clean up PR
This commit is contained in:
@@ -47,10 +47,10 @@ using NUnit.Framework;
|
||||
|
||||
namespace Newtonsoft.Json.Tests.Serialization
|
||||
{
|
||||
public interface IBase
|
||||
{
|
||||
DateTime CreatedOn { get; set; }
|
||||
}
|
||||
public interface IBase
|
||||
{
|
||||
DateTime CreatedOn { get; set; }
|
||||
}
|
||||
|
||||
public interface ITaskRepository : IBase
|
||||
{
|
||||
@@ -63,10 +63,10 @@ namespace Newtonsoft.Json.Tests.Serialization
|
||||
string Level { get; set; }
|
||||
}
|
||||
|
||||
public class Base : IBase
|
||||
{
|
||||
public DateTime CreatedOn { get; set; }
|
||||
}
|
||||
public class Base : IBase
|
||||
{
|
||||
public DateTime CreatedOn { get; set; }
|
||||
}
|
||||
|
||||
public class TaskRepository : Base, ITaskRepository
|
||||
{
|
||||
@@ -213,7 +213,7 @@ namespace Newtonsoft.Json.Tests.Serialization
|
||||
},
|
||||
'Repository': {
|
||||
'ConnectionString': 'server=.',
|
||||
'CreatedOn': '2015-04-01 20:00'
|
||||
'CreatedOn': '2015-04-01 20:00'
|
||||
},
|
||||
'People': [
|
||||
{
|
||||
@@ -227,14 +227,14 @@ namespace Newtonsoft.Json.Tests.Serialization
|
||||
'Name': 'Name3!'
|
||||
}
|
||||
}", new JsonSerializerSettings
|
||||
{
|
||||
ContractResolver = contractResolver
|
||||
});
|
||||
{
|
||||
ContractResolver = contractResolver
|
||||
});
|
||||
|
||||
Assert.IsNotNull(o);
|
||||
Assert.IsNotNull(o.Logger);
|
||||
Assert.IsNotNull(o.Repository);
|
||||
Assert.IsNotNull(o.Repository.CreatedOn);
|
||||
Assert.IsNotNull(o.Repository.CreatedOn);
|
||||
|
||||
Assert.AreEqual(2, count);
|
||||
|
||||
|
||||
@@ -2,7 +2,4 @@
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/PLACE_FIELD_ATTRIBUTE_ON_SAME_LINE/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/SPACE_AROUND_MULTIPLICATIVE_OP/@EntryValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/CodeStyle/CodeFormatting/CSharpFormat/WRAP_LINES/@EntryValue">False</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EAddAccessorOwnerDeclarationBracesMigration/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EMigrateBlankLinesAroundFieldToBlankLinesAroundProperty/@EntryIndexedValue">True</s:Boolean>
|
||||
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EMigrateThisQualifierSettings/@EntryIndexedValue">True</s:Boolean>
|
||||
</wpf:ResourceDictionary>
|
||||
@@ -883,20 +883,20 @@ namespace Newtonsoft.Json.Utilities
|
||||
{
|
||||
ValidationUtils.ArgumentNotNull(targetType, "targetType");
|
||||
|
||||
List<PropertyInfo> propertyInfos;
|
||||
List<PropertyInfo> propertyInfos;
|
||||
|
||||
if (!targetType.IsInterface())
|
||||
{
|
||||
propertyInfos = new List<PropertyInfo>(targetType.GetProperties(bindingAttr));
|
||||
}
|
||||
else
|
||||
{
|
||||
propertyInfos = (new Type[] { targetType })
|
||||
.Concat(targetType.GetInterfaces())
|
||||
.SelectMany(i => i.GetProperties(bindingAttr)).ToList();
|
||||
}
|
||||
if (!targetType.IsInterface())
|
||||
{
|
||||
propertyInfos = new List<PropertyInfo>(targetType.GetProperties(bindingAttr));
|
||||
}
|
||||
else
|
||||
{
|
||||
propertyInfos = (new Type[] { targetType })
|
||||
.Concat(targetType.GetInterfaces())
|
||||
.SelectMany(i => i.GetProperties(bindingAttr)).ToList();
|
||||
}
|
||||
|
||||
GetChildPrivateProperties(propertyInfos, targetType, bindingAttr);
|
||||
GetChildPrivateProperties(propertyInfos, targetType, bindingAttr);
|
||||
|
||||
// a base class private getter/setter will be inaccessable unless the property was gotten from the base class
|
||||
for (int i = 0; i < propertyInfos.Count; i++)
|
||||
|
||||
Reference in New Issue
Block a user