【发布时间】:2010-09-02 21:14:27
【问题描述】:
我正在阅读这篇博文:http://www.shakie.co.uk/ramblings/feature-driven-development-riding-the-waves-of-change/,偶然发现了有关 TestDox 的部分:
直接引用(因此是 PHP):
以下面的测试用例为 例子
class InvoiceTest extends PHPUnit_Framework_TestCase
{
public function testValueIsInitiallyZero() {
$invoice = new Invoice();
$this->assertEquals(0.00, $invoice->getValue());
}
public function testWillCloseAutomaticallyIfWholeValueIsPaid() {
$invoice = Invoice::getInvoiceById(1);
$invoice->payAmount(100.00);
$this->assertEquals(true, $invoice->isClosed());
}
}
在 TestDox 格式中,这将 翻译成:
发票
[x] 初始值为零
[x] 如果全额支付,将自动关闭
这对于我正在从事的一些更敏捷的项目非常有用。我一直在研究 TestDox 并试图追踪 NTestDox,因为我是一个 .NET 人。
三个问题在这里合二为一:
有人找到 NTestDox 的副本吗? (我看到 google 中唯一有用的结果中不存在页面)
- http://www.emxtechnologies.com/ntestdox
- http://www.projectdistributor.net/projects/Project.aspx?projectId=87
从您的单元测试生成文档是一个好的计划吗?
有人知道.NET 的任何其他框架吗?
【问题讨论】:
标签: .net unit-testing agile