JavaScript Advent Calendar 2011 (Node.js/WebSocketsコース) 12日目の記事です。 Node.js におけるテストフレームである、vows について書いてみました。 はじめに この記事では、README.md や 本家 Web サイトのドキュメントに載っていないことを主に書いています。 最新バージョンである 0.6.0 の vows を元に、おさらいした後、以下の3つについて説明します。 assert teardown sub-events 0. vows についておさらい vows は、Node.js 向けの RSpec のような BDD できるフレームワーク です。 vows は非同期なコードをテストするために作られたフレームワークとなっています。 インストール vows は npm を使って下記コマンドでインストールできます。 $ n
Source Code: lib/events.js Much of the Node.js core API is built around an idiomatic asynchronous event-driven architecture in which certain kinds of objects (called "emitters") emit named events that cause Function objects ("listeners") to be called. For instance: a net.Server object emits an event each time a peer connects to it; a fs.ReadStream emits an event when the file is opened; a stream e
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く