Example #1
0
        public void TestSortActuators(string culture)
        {
            List <IActuator> actuators = new List <IActuator>();
            var actuator0 = new TestActuator(ActionSpec.MakeContinuous(2), "Apple");
            var actuator1 = new TestActuator(ActionSpec.MakeContinuous(2), "Æble");

            actuators.Add(actuator0);
            actuators.Add(actuator1);

            var originalCulture = CultureInfo.CurrentCulture;

            CultureInfo.CurrentCulture = new CultureInfo(culture);
            ActuatorManager.SortActuators(actuators);
            CultureInfo.CurrentCulture = originalCulture;

            Assert.AreEqual(actuator1, actuators[0]);
            Assert.AreEqual(actuator0, actuators[1]);
        }