public void Should_contain_registered_keys() { var registry = new LocalizationRegistry(new Cache()); registry.RegisterTranslation("en", registry.GetTranslationKeys().FirstOrDefault(), "test1"); registry.RegisterTranslation("fr", registry.GetTranslationKeys().FirstOrDefault(), "test2"); registry.GetTranslation("en", registry.GetTranslationKeys().FirstOrDefault()).Should().Be("test1"); registry.GetTranslation("fr", registry.GetTranslationKeys().FirstOrDefault()).Should().Be("test2"); registry.GetTranslations(registry.GetTranslationKeys().FirstOrDefault()).Count.Should().Be(2); }
public void Should_have_all_translation_keys() { var registry = new LocalizationRegistry(new Cache()); registry.GetTranslationKeys().Length.Should().Be(11); }