/// <summary> /// 添加消息 /// </summary> private void Add(FormatterBase formatter) { string result = formatter.Format(); if (string.IsNullOrWhiteSpace(result)) { return; } Result.AddLine("{0}. {1}", Line++, result); }
public void Format_ShouldThrowNotImplementedException() { var fb = new FormatterBase(); Assert.Throws <NotImplementedException>(() => fb.Format(string.Empty)); }
/// <summary> /// 添加消息 /// </summary> private void Add( FormatterBase formatter ) { string result = formatter.Format(); if ( string.IsNullOrWhiteSpace( result ) ) return; Result.AddLine( "{0}. {1}", Line++, result ); }