1

我将 MSpec 和 Visual Studio 2010 与 Resharper 5.1 一起使用。我已将 MSpec 测试运行器插件安装到 resharper 中,但它无法正常工作。这是我的测试:

    public class when_I_click_create_investment_manager : with_main_window
    {
        Establish I_am_viewing_the_main_page = () => mainWindowViewModel = new MainWindowViewModel();
        Because the_user_clicks_create = () => mainWindowViewModel.CreateInvestmentManager.Execute(null);
        It should_show_the_investment_manager_details_screen = () => mainWindowViewModel.CurrentWorkspace.ShouldBeOfType(typeof(IInvestmentManagerDetailsViewModel));
        It should_set_the_edit_screen_to_create_mode = () => mainWindowViewModel.CurrentWorkspace.Mode.ShouldEqual(WorkspaceMode.New);  
    }

    public class with_main_window
    {
        protected static IMainWindowViewModel mainWindowViewModel;
    }

但是测试运行器没有运行我的断言但仍然显示成功,我得到的输出是:

替代文字

4

1 回答 1

3

您的问题很可能是由项目目录中的 MSpec 插件 + 程序集的过时版本引起的。请确保您在 ReSharper 插件目录和您的项目中都有来自 CodeBetter CI 的最新版本的 MSpec 。

于 2010-08-06T13:51:43.913 回答