Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Fix test suite #27

Merged
merged 3 commits into from Jul 18, 2012
Jump to file or symbol
Failed to load files and symbols.
+4 −23
Split
View
@@ -26,7 +26,6 @@ vows.describe("Charges API").addBatch({
},
'returns a charge' : function(err, response) {
assert.isNull(err);
- console.log("response", response);
assert.isDefined(response);
assert.equal(response.object, 'charge');
assert.isDefined(response.id);
View
@@ -18,7 +18,6 @@ vows.describe("Customer API").addBatch({
},
'returns a customer': function(err, response) {
assert.isNull(err);
- console.log("response", response);
assert.isDefined(response);
assert.equal(response.object, 'customer');
assert.equal(response.email, "foo@example.com");
@@ -35,7 +34,7 @@ vows.describe("Customer API").addBatch({
topic: function(create_err, customer) {
stripe.customers.update(customer.id, {
description: "test",
- card: { number: "4111111111111111",
+ card: { number: "4242424242424242",
exp_month: 12,
exp_year: 2020,
name: "T. Ester"
@@ -50,11 +49,9 @@ vows.describe("Customer API").addBatch({
},
'Delete customer' : {
topic: function(create_err, customer) {
- console.log("customer for deletion", customer);
stripe.customers.del(customer.id, this.callback);
},
'Customer was deleted': function(err,response) {
- console.log("response", response);
assert.isNull(err);
assert.isTrue(response.deleted);
}
View
@@ -27,7 +27,6 @@ vows.describe("Invoice API").addBatch({
'returns a plan': function(err, response) {
assert.isNull(err);
- console.log('response', response);
assert.isDefined(response);
assert.equal(response.object, 'plan');
assert.equal(response.id, 'foobarbaz_plan');
@@ -40,7 +39,7 @@ vows.describe("Invoice API").addBatch({
stripe.customers.create({
email: "foo@example.com",
plan: plan.id,
- card: { number: "4111111111111111",
+ card: { number: "4242424242424242",
exp_month: d.getMonth() + 1,
exp_year: d.getFullYear() + 1,
name: "T. Ester"
@@ -50,7 +49,6 @@ vows.describe("Invoice API").addBatch({
'returns a customer': function(err, response) {
assert.isNull(err);
- console.log("response", response);
assert.isDefined(response);
assert.equal(response.object, 'customer');
assert.equal(response.email, "foo@example.com");
@@ -68,7 +66,6 @@ vows.describe("Invoice API").addBatch({
'created a charge': function(err, response) {
assert.isNull(err);
- console.log('response', response);
assert.isDefined(response);
assert.equal(response.object, 'charge');
assert.equal(response.paid, true);
@@ -80,7 +77,6 @@ vows.describe("Invoice API").addBatch({
'receives a list of invoices': function(err, response) {
assert.isNull(err);
- console.log('response', response);
assert.isDefined(response);
assert.isArray(response.data);
assert.strictEqual(response.data.length > 0, true);
@@ -97,7 +93,6 @@ vows.describe("Invoice API").addBatch({
'received invoice': function(err, response) {
assert.isNull(err);
- console.log('response', response);
assert.isDefined(response);
assert.equal(response.object, 'invoice');
assert.strictEqual(response.total > 0, true);
@@ -109,7 +104,6 @@ vows.describe("Invoice API").addBatch({
'received upcoming invoice': function(err, response) {
assert.isNull(err);
- console.log('response', response);
assert.isDefined(response);
assert.equal(response.object, 'invoice');
assert.strictEqual(response.total > 0, true);
@@ -121,7 +115,6 @@ vows.describe("Invoice API").addBatch({
'customer deleted': function(err, response) {
assert.isNull(err);
- console.log('response', response);
assert.isDefined(response);
assert.isTrue(response.deleted);
},
@@ -132,7 +125,6 @@ vows.describe("Invoice API").addBatch({
'deleted the subscription plan': function(err, response) {
assert.isNull(err);
- console.log('response', response);
assert.isDefined(response);
assert.isTrue(response.deleted);
}
View
@@ -36,7 +36,6 @@ vows.describe("Subscription Plans API").addBatch({
},
'returns a plan': function(err, response) {
assert.isNull(err);
- console.log('response', response);
assert.isDefined(response);
assert.equal(response.object, 'plan');
assert.equal(response.id, 'foobarbaz_plan');
@@ -53,7 +52,6 @@ vows.describe("Subscription Plans API").addBatch({
var p = getFirstPlan();
assert.isNull(err);
- console.log('response', response);
assert.isDefined(response);
assert.equal(response.id, p.id);
}
@@ -70,7 +68,6 @@ vows.describe("Subscription Plans API").addBatch({
},
'returns a plan': function(err, response) {
assert.isNull(err);
- console.log('response', response);
assert.isDefined(response);
assert.equal(response.object, 'plan');
assert.equal(response.id, 'bazbarfoo_plan');
@@ -85,7 +82,6 @@ vows.describe("Subscription Plans API").addBatch({
},
'returns a list of plans': function(err, response) {
assert.isNull(err);
- console.log('response', response);
assert.isDefined(response);
assert.isNumber(response.count);
@@ -102,7 +98,6 @@ vows.describe("Subscription Plans API").addBatch({
var p = getFirstPlan(true);
- console.log('response', response);
assert.isDefined(response);
assert.isTrue(response.deleted);
assert.equal(response.id, p.id);
@@ -118,7 +113,6 @@ vows.describe("Subscription Plans API").addBatch({
var p = getFirstPlan(true);
- console.log('response', response);
assert.isDefined(response);
assert.isTrue(response.deleted);
assert.equal(response.id, p.id);
View
@@ -18,12 +18,11 @@ vows.describe("Tokens API").addBatch({
'Create token' : {
topic: function() {
stripe.token.create({
- card: { number: "4111111111111111",
+ card: { number: "4242424242424242",
exp_month: 1,
exp_year: 2021,
name: "J. Ester"
- },
- amount: 77
+ }
}, this.callback);
},
'Got card token': function(err, token) {