test: address review feedback — cover WaitForAsync predicate overload; clarify ChildrenAccessor parity row; dedup object-method exclusion
This commit is contained in:
@@ -100,6 +100,11 @@ public class CompileSurfaceParityTests
|
||||
{
|
||||
new object[] { typeof(AttributeAccessor), typeof(ScriptCompileSurface.CompileAttributeAccessor) },
|
||||
new object[] { typeof(CompositionAccessor), typeof(ScriptCompileSurface.CompileCompositionAccessor) },
|
||||
// ChildrenAccessor currently exposes only an indexer (no public instance
|
||||
// methods), so this row guards nothing today. It is kept so that if a
|
||||
// callable method is ever added to ChildrenAccessor, this Theory begins
|
||||
// enforcing a mirror for it automatically — rather than silently
|
||||
// re-opening the WaitAsync-class gap.
|
||||
new object[] { typeof(ChildrenAccessor), typeof(ScriptCompileSurface.CompileChildrenAccessor) },
|
||||
};
|
||||
|
||||
@@ -138,14 +143,6 @@ public class CompileSurfaceParityTests
|
||||
{
|
||||
const BindingFlags flags = BindingFlags.Public | BindingFlags.Instance;
|
||||
|
||||
var objectMembers = new HashSet<string>(StringComparer.Ordinal)
|
||||
{
|
||||
nameof(ToString),
|
||||
nameof(GetHashCode),
|
||||
nameof(Equals),
|
||||
nameof(GetType),
|
||||
};
|
||||
|
||||
var names = new HashSet<string>(StringComparer.Ordinal);
|
||||
|
||||
foreach (var property in type.GetProperties(flags))
|
||||
@@ -157,7 +154,7 @@ public class CompileSurfaceParityTests
|
||||
// property itself is already counted by name above.
|
||||
if (method.IsSpecialName)
|
||||
continue;
|
||||
if (objectMembers.Contains(method.Name))
|
||||
if (ObjectMethodNames.Contains(method.Name))
|
||||
continue;
|
||||
names.Add(method.Name);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user