You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Remove the doc comment about throwing an exception and leave the method as-is
Introduce a new method that throws an exception and name it GetSingleDerivedAttributeOrDefault. Note that throwing exception may still be relevant even if AllowMultiple is not true (ONLY IF the attribute is not sealed). See UTA_MultipleExpectedExceptionsOnTestMethod is unused #4331 for details.
Revise all usages, and switch from GetFirstDerivedAttributeOrDefault to GetSingleDerivedAttributeOrDefault if needed.
My expectation is that after we do these three steps, we will end up having GetFirstDerivedAttributeOrDefault called with sealed attributes only. If this happened, we can switch all these to GetFirstNonDerivedAttributeOrDefault and delete GetFirstDerivedAttributeOrDefault
The text was updated successfully, but these errors were encountered:
Doc says:
Implementation:
My suggestion:
GetSingleDerivedAttributeOrDefault
. Note that throwing exception may still be relevant even if AllowMultiple is not true (ONLY IF the attribute is not sealed). SeeUTA_MultipleExpectedExceptionsOnTestMethod
is unused #4331 for details.GetFirstDerivedAttributeOrDefault
toGetSingleDerivedAttributeOrDefault
if needed.GetFirstDerivedAttributeOrDefault
called with sealed attributes only. If this happened, we can switch all these toGetFirstNonDerivedAttributeOrDefault
and deleteGetFirstDerivedAttributeOrDefault
The text was updated successfully, but these errors were encountered: