30 references to LocalizedString
Aspire.Dashboard.Tests (2)
Model\TestStringLocalizer.cs (2)
10
public LocalizedString this[string name] => new
LocalizedString
(name, $"Localized:{name}");
11
public LocalizedString this[string name, params object[] arguments] => new
LocalizedString
(name, $"Localized:{name}:" + string.Join("+", arguments));
Microsoft.AspNetCore.Mvc.DataAnnotations.Test (16)
CompareAttributeAdapterTest.cs (1)
67
.Returns(new
LocalizedString
(attribute.ErrorMessage, expectedMessage));
DataAnnotationsMetadataProviderTest.cs (7)
261
.Returns(new
LocalizedString
("DisplayNameValue", "Name from DisplayNameAttribute"));
299
.Returns(new
LocalizedString
("DisplayNameValue", "Name from DisplayNameAttribute"));
564
.Returns(() => new
LocalizedString
("Model_Name", "name from localizer " + CultureInfo.CurrentCulture));
567
.Returns(() => new
LocalizedString
("Model_Description", "description from localizer " + CultureInfo.CurrentCulture));
570
.Returns(() => new
LocalizedString
("Model_Prompt", "prompt from localizer " + CultureInfo.CurrentCulture));
837
.Returns<string>((index) => new
LocalizedString
(index, index + " value"));
1713
return new
LocalizedString
(k, $"{k} {CultureInfo.CurrentCulture}");
DataAnnotationsModelValidatorTest.cs (1)
371
var localizedString = new
LocalizedString
(attribute.ErrorMessage, "Longueur est invalide : 4");
FileExtensionsAttributeAdapterTest.cs (1)
116
.Returns(new
LocalizedString
(attribute.ErrorMessage, expectedErrorMessage));
MaxLengthAttributeAdapterTest.cs (2)
31
.Returns(new
LocalizedString
(attribute.ErrorMessage, expectedMessage));
116
var localizedString = new
LocalizedString
(errorKey, "Longueur est invalide");
MinLengthAttributeAdapterTest.cs (1)
31
.Returns(new
LocalizedString
(attribute.ErrorMessage, expectedMessage));
RangeAttributeAdapterTest.cs (1)
61
.Returns(new
LocalizedString
(attribute.ErrorMessage, expectedMessage));
RequiredAttributeAdapterTest.cs (1)
32
.Returns(new
LocalizedString
(attribute.ErrorMessage, expectedMessage));
StringLengthAttributeAdapterTest.cs (1)
32
.Returns(new
LocalizedString
(attribute.ErrorMessage, expectedMessage));
Microsoft.AspNetCore.Mvc.Localization.Test (8)
HtmlLocalizerTest.cs (4)
18
var localizedString = new
LocalizedString
("Hello", "Bonjour");
36
var localizedString = new
LocalizedString
("Hello", "Bonjour test");
101
var localizedString = new
LocalizedString
("Hello", format);
139
var localizedString = new
LocalizedString
("Hello", format);
TestStringLocalizer.cs (4)
32
return new
LocalizedString
(name, value + name);
52
return new
LocalizedString
(name, value + name + argument);
59
allStrings.Add(new
LocalizedString
("Hello", "World"));
63
allStrings.Add(new
LocalizedString
("Foo", "Bar"));
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (4)
RemoteAttributeBaseTest.cs (2)
264
var localizedString = new
LocalizedString
("Fred", expected);
401
var localizedString = new
LocalizedString
("Fred", expected);
Rendering\HtmlHelperDisplayExtensionsTest.cs (1)
336
return new
LocalizedString
(key, "created from IStringLocalizer");
Rendering\HtmlHelperSelectTest.cs (1)
1306
.Returns<string>((s) => { return new
LocalizedString
(s, s + " " + CultureInfo.CurrentCulture); });