示例#1
0
        public void CreateAndDeleteChangelog()
        {
            string    cpath = path + "\\Changelogs\\test.json";
            Changelog c     = new Changelog("test");

            directory.CreateChangelog(c);
            Assert.IsTrue(File.Exists(cpath));
            string text = File.ReadAllText(cpath);

            Assert.AreEqual(text, "{\r\n  \"Hash\": \"test\",\r\n  \"Added\": [],\r\n  \"Modified\": [],\r\n  \"Removed\": [],\r\n  \"Renamed\": []\r\n}");
            directory.DeleteChangelog(c);
            Assert.IsFalse(File.Exists(cpath));
        }
示例#2
0
 /// <summary>
 /// Deletes a Changelog from the file directory
 /// </summary>
 /// <param name="changelog"></param>
 public void DeleteChangelog(Changelog changelog)
 {
     directory.DeleteChangelog(changelog);
 }