Permalink
Browse files

Add test for unicodeString

  • Loading branch information...
1 parent 4993413 commit 8678e7900f07b164673c32c3bfda3361927d4939 @peterbraden peterbraden committed Feb 12, 2013
Showing with 10 additions and 1 deletion.
  1. +10 −1 test/index.js
View
11 test/index.js
@@ -1,13 +1,22 @@
var cards = require('../lib/cards')
, vows = require('vows')
+ , assert = require('assert')
vows.describe("Card Deck").addBatch({
"Poker Deck": {
- topic: new cards.PokerDeck(),
+ topic: function(){return new cards.PokerDeck()},
+
+ draw : function(deck){
+ var card = deck.draw();
+ assert.equal(card.toString(), "[Card club:2]");
+ assert.equal(card.unicodeString(), "2♣");
+ },
+
shuffleAll : function(deck){
deck.shuffleAll()
}
+
}

0 comments on commit 8678e79

Please sign in to comment.