public void CustomLocalizationEmbeddedScriptsAssembly()
        {
            var assembly = Assembly.GetExecutingAssembly();

            Localization.AddLocale("ru", "TestLocalizationRu", assembly);
            Assert.IsTrue(_moqLocalization.Object.GetAllLocalizationEmbeddedScripts().Select(s => s.SourceAssembly).Contains(assembly));
        }
        public void CustomLocalizationReleaseMode()
        {
            Mock <Localization> _localization = new Mock <Localization>();

            _localization.Setup(p => p.IsLocalizationEnabled()).Returns(true);
            _localization.Setup(p => p.BuiltinLocales).Returns(new[] { "en", "en-AU" });
            _localization.Setup(p => p.IsDebuggingEnabled()).Returns(false);

            var assembly = Assembly.GetExecutingAssembly();

            Localization.AddLocale("ru", "TestLocalizationRu", assembly);

            Assert.IsTrue(_localization.Object.GetLocalizationScriptReferences().Select(s => s.Name).Contains("TestLocalizationRu.min.js"));
        }
 public void CustomLocalizationEmbeddedScriptsName()
 {
     Localization.AddLocale("ru", "TestLocalizationRu", Assembly.GetExecutingAssembly());
     Assert.IsTrue(_moqLocalization.Object.GetAllLocalizationEmbeddedScripts().Select(s => s.Name).Contains("TestLocalizationRu"));
 }
 public void CustomLocale()
 {
     Localization.AddLocale("ru", "TestLocalizationRu", Assembly.GetExecutingAssembly());
     Assert.AreEqual("ru", _moqLocalization.Object.GetLocaleKey());
 }