Skip to content

Commit 2dd8012

Browse files
author
James Halliday
committed
separate browser harness with exportified index.html, move should into the test itself
1 parent 258bc69 commit 2dd8012

4 files changed

Lines changed: 8 additions & 1 deletion

File tree

test/browser.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/*jshint node:true, evil:true */
2+
/*global describe:true, it:true, PAYPAL:true, document:true, window:true */
3+
4+
document.body.innerHTML = require('./index.html.js');
5+
6+
require('./test.js');

test/index.html.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

test/server.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
/*global describe:true, it:true, PAYPAL:true, document:true, window:true */
33

44
var fs = require('fs'),
5-
should = require('should'),
65
jsdom = require('jsdom').jsdom;
76

87
global.document = jsdom(fs.readFileSync(__dirname + '/index.html').toString());

test/test.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
var PAYPAL = require('../src/paypal-button.js');
2+
require('should');
23

34
// Test the object's integrity
45
describe('PAYPAL.apps.ButtonFactory', function () {

0 commit comments

Comments
 (0)