public void EditProjectAndSave()
        {
            var uiSvc = new FakeShellUiService();
            var epi = new EditProjectInteractor();
            var p = CreateTestProject();

            var ret = epi.EditProjectProperties(uiSvc, p, delegate(Project_v1 project)
            {
                Assert.AreEqual("test.exe", project.Input.Filename);
                Assert.AreEqual("10000", project.Input.Address);
                Assert.AreEqual("test.asm", project.Output.DisassemblyFilename);
                Assert.AreEqual("test.dis", project.Output.IntermediateFilename);
                Assert.AreEqual("test.h", project.Output.TypesFilename);
                Assert.AreEqual("test.c", project.Output.OutputFilename);
            });
            Assert.IsTrue(ret);
        }
 public void EditProjectAndCancel()
 {
     FakeShellUiService uiSvc = new FakeShellUiService();
     uiSvc.SimulateUserCancel = true;
     var project = CreateTestProject();
     var epi = new EditProjectInteractor();
     var ret = epi.EditProjectProperties(uiSvc, project, delegate(Project_v1 p)
     {
         Assert.Fail("Should not save if user cancels.");
     });
     Assert.IsFalse(ret);
     Assert.AreEqual("test.exe", project.Input.Filename);
     Assert.AreEqual("10000", project.Input.Address);
     Assert.AreEqual("test.asm", project.Output.DisassemblyFilename);
     Assert.AreEqual("test.dis", project.Output.IntermediateFilename);
     Assert.AreEqual("test.h", project.Output.TypesFilename);
     Assert.AreEqual("test.c", project.Output.OutputFilename);
 }