public void WhenNewLinesAreContained_ReplacesNewLinesWithSpaces() { const string testString = "This is a test\nwith multiple new\nline\ncharacters."; const string expected = "This is a test with multiple new line characters."; var actual = _converter.Convert(testString, null, null, null); Assert.AreEqual(expected, actual); }
public void SetAppStatus(string text) { text ??= ""; text = SingleLineConverter.Convert(text); Dispatcher.BeginInvoke(new Action(() => { tssAppStatus.Text = text; })); }
public void SetStatus(string text, bool error) { text ??= ""; text = SingleLineConverter.Convert(text); Dispatcher.BeginInvoke(new Action(() => { tssStatus.Text = text; tssStatus.Foreground = error ? new SolidColorBrush(UIColors.ErrorColor) : SystemColors.WindowTextBrush; })); }