Testing in Node.js
![]() |
http://blog.bughuntress.com/automated-testing/automated-testing-with-behavior-driven-testing |
A test driven development cycle simplifies the thought process of writing code, makes it easier, and quicker in the long run. But just writing tests is not enough by itself, knowing the kinds of tests to write and how to structure code to conform to this pattern is what it's all about. In this article we will take a look at building a small app in Node.js following a TDD pattern.
— Tuts+ http://t.co/qT6gvyd5fn @tutsplus 에서
Mocha is a feature-rich JavaScript test framework running on node.js and the browser, making asynchronous testing simple and fun. Mocha tests run serially, allowing for flexible and accurate reporting, while mapping uncaught exceptions to the correct test cases.
Vows is a behavior driven development framework for Node.js.
Vows was built from the ground up to test asynchronous code. It executes your tests in parallel when it makes sense, and sequentially when there are dependencies.
Emphasis was put on speed of execution, clarity and user experience.
Chai is a BDD / TDD assertion library for node and the browser that can be delightfully paired with any javascript testing framework.
댓글 없음:
댓글 쓰기