示例#1
0
        public void Mfi_AddMetadata()
        {
            Given_Loader();
            Given_MainFormInteractor();
            Given_DecompilerInstance();
            decompiler.Expect(d => d.LoadMetadata("foo.def")).Return(new TypeLibrary());
            services.AddService(typeof(IDecompilerService), dcSvc);
            uiSvc.Expect(u => u.ShowOpenFileDialog(null)).IgnoreArguments().Return("foo.def");
            Given_CommandNotHandledBySubwindow();
            this.tcHostSvc.Stub(t => t.Execute(null)).IgnoreArguments().Return(false);
            mr.ReplayAll();

            When_MainFormInteractorWithLoader();
            interactor.Execute(new CommandID(CmdSets.GuidReko, CmdIds.FileAddMetadata));

            mr.VerifyAll();
        }