public void Label_text_is_properly_escaped() { Assert.Equal(@"help\nnewline", PrometheusConventions.EscapeLabel("help\nnewline")); Assert.Equal(@"a\\b", PrometheusConventions.EscapeLabel("a\\b")); Assert.Equal(@"it's not \""OK\""", PrometheusConventions.EscapeLabel("it's not \"OK\"")); Assert.Equal(@"complex\nexample\\with\\multiple\""escapes\""\n", PrometheusConventions.EscapeLabel("complex\nexample\\with\\multiple\"escapes\"\n")); }
public void Help_text_is_properly_escaped() { Assert.Equal(@"help\nnewline", PrometheusConventions.EscapeHelp("help\nnewline")); Assert.Equal(@"a\\b", PrometheusConventions.EscapeHelp("a\\b")); Assert.Equal(@"it's ""OK""", PrometheusConventions.EscapeHelp("it's \"OK\"")); Assert.Equal(@"complex\nexample\\with\\multiple\n", PrometheusConventions.EscapeHelp("complex\nexample\\with\\multiple\n")); }
public void Label_text_is_properly_escaped() { Assert.Equal(@"help\nnewline", PrometheusConventions.EscapeLabel("help\nnewline")); Assert.Equal(@"a\b", PrometheusConventions.EscapeLabel("a\\b")); Assert.Equal(@"it's not \""OK\""", PrometheusConventions.EscapeLabel("it's not \"OK\"")); }
public void Help_text_is_properly_escaped() { Assert.Equal(@"help\nnewline", PrometheusConventions.EscapeHelp("help\nnewline")); Assert.Equal(@"a\b", PrometheusConventions.EscapeHelp("a\\b")); Assert.Equal(@"it's ""OK""", PrometheusConventions.EscapeHelp("it's \"OK\"")); }
public void AreValidHistogramNames_should_return_false_when_one_of_the_names_is_invalid(params string[] name) { Assert.False(PrometheusConventions.AreValidHistogramNames(name)); }
public void IsValidHistogramName_should_return_false_for_invalid_names(string name) { Assert.False(PrometheusConventions.IsValidHistogramName(name)); }
public void IsValidLabel_should_return_true_for_valid_labels(string label) { Assert.True(PrometheusConventions.IsValidName(label)); }
public void IsValidLabel_should_return_false_for_invalid_labels(string label) { Assert.False(PrometheusConventions.IsValidLabel(label)); }
public void IsValidName_should_return_true_for_valid_names(string name) { Assert.True(PrometheusConventions.IsValidName(name)); }