public void RoundtripCriticalBuildMessageEventArgs() { var args = new CriticalBuildMessageEventArgs( "Subcategory", "Code", "File", 1, 2, 3, 4, "Message", "Help", "SenderName", DateTime.Parse("12/12/2015 06:11:56 PM")); Roundtrip(args, e => e.Code, e => e.ColumnNumber.ToString(), e => e.EndColumnNumber.ToString(), e => e.EndLineNumber.ToString(), e => e.File, e => e.LineNumber.ToString(), e => e.Message, e => e.ProjectFile, e => e.Subcategory); }
private BuildEventArgs ReadCriticalBuildMessageEventArgs() { BuildEventArgsFields fields = ReadBuildEventArgsFields(); /*(MessageImportance)*/ ReadInt32(); CriticalBuildMessageEventArgs e = new CriticalBuildMessageEventArgs( fields.Subcategory, fields.Code, fields.File, fields.LineNumber, fields.ColumnNumber, fields.EndLineNumber, fields.EndColumnNumber, fields.Message, fields.HelpKeyword, fields.SenderName, fields.Timestamp) { BuildEventContext = fields.BuildEventContext, ProjectFile = fields.ProjectFile }; return(e); }
public void EventArgsCtors() { CriticalBuildMessageEventArgs cbmea = new CriticalBuildMessageEventArgs2(); cbmea = new CriticalBuildMessageEventArgs("Subcategory", "Code", "File", 1, 2, 3, 4, "Message", "HelpKeyword", "Sender"); cbmea = new CriticalBuildMessageEventArgs("Subcategory", "Code", "File", 1, 2, 3, 4, "Message", "HelpKeyword", "Sender", DateTime.Now); cbmea = new CriticalBuildMessageEventArgs("Subcategory", "Code", "File", 1, 2, 3, 4, "{0}", "HelpKeyword", "Sender", DateTime.Now, "Message"); cbmea = new CriticalBuildMessageEventArgs(null, null, null, 0, 0, 0, 0, null, null, null); cbmea = new CriticalBuildMessageEventArgs(null, null, null, 0, 0, 0, 0, null, null, null, DateTime.Now); cbmea = new CriticalBuildMessageEventArgs(null, null, null, 0, 0, 0, 0, null, null, null, DateTime.Now, null); }
private void Write(CriticalBuildMessageEventArgs e) { Write(BinaryLogRecordKind.CriticalBuildMessage); WriteMessageFields(e); }