ApprovalTests.Namers.StackTraceParsers.AttributeStackTraceParser.GetFirstFrameForAttribute C# (CSharp) Method

GetFirstFrameForAttribute() public static method

public static GetFirstFrameForAttribute ( ApprovalUtilities.CallStack.Caller caller, string attributeName ) : ApprovalUtilities.CallStack.Caller
caller ApprovalUtilities.CallStack.Caller
attributeName string
return ApprovalUtilities.CallStack.Caller
		public static Caller GetFirstFrameForAttribute(Caller caller, string attributeName)
		{
			var firstFrameForAttribute =
				caller.Callers.FirstOrDefault(c => ContainsAttribute(c.Method.GetCustomAttributes(false), attributeName));
			return firstFrameForAttribute;
		}