public void Empty() { using var reader = new StringReader(string.Empty); var nameReader = new NameTextReader(reader); Assert.Empty(nameReader); }
public void Whitespace() { using var reader = new StringReader("\n\n\n\n"); var nameReader = new NameTextReader(reader); Assert.Empty(nameReader); }
public void Comments() { using var reader = new StringReader("# comment 1\n# comment 2"); var nameReader = new NameTextReader(reader); Assert.Empty(nameReader); }
public void SingleLine() { const string text = @" en-US Some pattern "; using var reader = new StringReader(text); var nameReader = new NameTextReader(reader); var pattern = Assert.Single(nameReader); Assert.Equal("en-US", pattern.Culture); Assert.Equal("Some pattern", pattern.Pattern); }