【发布时间】:2011-04-25 13:42:04
【问题描述】:
我有一个表格,需要填写几个字段。但是,只有一个字段是必填的。所以,我想出了以下规范:
[Subject(typeof(CompanyHomeController))]
public class when_the_save_button_is_clicked
{
private It should_verify_that_the_company_name_has_been_filled;
private It should_show_some_text_next_to_the_company_field_if_it_has_not_been_filled;
private It should_submit_all_the_details_on_the_form_if_there_are_no_errors;
private It should_take_the_user_back_to_the_list_of_companies;
}
现在我想实现它,但我感到困惑,因为它听起来很像功能测试,我必须使用 mvccontrib.watin dll 之类的东西。我对它确实是功能测试吗?我是否为 BDD 制定了“错误”的规范?
【问题讨论】: