Browse Source

Fixed System_Rune_ColumnWidth unit test.

BDisp 2 years ago
parent
commit
436c171478
1 changed files with 2 additions and 2 deletions
  1. 2 2
      UnitTests/TextFormatterTests.cs

+ 2 - 2
UnitTests/TextFormatterTests.cs

@@ -2841,12 +2841,12 @@ namespace Terminal.Gui.Core {
 
 			c = new System.Rune (31);
 			Assert.Equal (-1, Rune.ColumnWidth (c));        // non printable character
-			Assert.Equal (-1, ustring.Make (c).ConsoleWidth);
+			Assert.Equal (0, ustring.Make (c).ConsoleWidth);// ConsoleWidth only returns zero or greater than zero
 			Assert.Equal (1, ustring.Make (c).Length);
 
 			c = new System.Rune (127);
 			Assert.Equal (-1, Rune.ColumnWidth (c));       // non printable character
-			Assert.Equal (-1, ustring.Make (c).ConsoleWidth);
+			Assert.Equal (0, ustring.Make (c).ConsoleWidth);
 			Assert.Equal (1, ustring.Make (c).Length);
 		}