コード例 #1
0
        public void TestSaveConfiguration()
        {
            var fs = new FlowSensor();

            var xmlHelper = new XmlConfigurationHelper();
            fs.SaveConfiguration(xmlHelper.GetEventArgs());

            var expectedConfig = "<plugins><plugin name=\"User Activity\" enabled=\"True\" /></plugins>";
            Assert.That(xmlHelper.GetPluginsElement().OuterXml, Is.EqualTo(expectedConfig));
        }
コード例 #2
0
        public void TestSaveConfiguration()
        {
            var sc = new CherryTomato.SkypeController.SkypeController();
            sc.InPomodoroTextTemplate = "status";

            var xmlHelper = new XmlConfigurationHelper();
            sc.SaveConfiguration(xmlHelper.GetEventArgs());

            var expectedConfig = "<plugins><plugin name=\"Skype\" enabled=\"True\"><inPomodoroStatus>status</inPomodoroStatus></plugin></plugins>";
            Assert.That(xmlHelper.GetPluginsElement().OuterXml, Is.EqualTo(expectedConfig));
        }