Beispiel #1
0
        public void AddUpdateDeleteScriptWithUniqueNameShouldPass()
        {
            Script script = new Script
            {
                Type = "TEST",
                Name = "Test Script 2",
                Path = "TEST",
                Arguments = "TEST",
                Details = "TEST"
            };

            Assert.AreEqual(_store.AddScript(script), true);

            int index = _store.GetScriptIndexByName(script.Name);

            Script script_Updated = new Script
            {
                Type = "TEST_Updated",
                Name = "TEST_Updated",
                Path = "TEST_Updated",
                Arguments = "TEST_Updated",
                Details = "TEST_Updated"
            };

            Assert.AreEqual(_store.UpdateScript(index, script_Updated), true);

            index = _store.GetScriptIndexByName(script_Updated.Name);

            _store.DeleteScript(index);

        }
Beispiel #2
0
 public void DeleteScript(int index)
 {
     _scriptStore.DeleteScript(index);
 }