Permalink
Browse files

Fix broken tests due to missing sample data.

  • Loading branch information...
1 parent 7a67b00 commit abaa6f1645911216627bc8a68ece7abb471e5383 @mbostock mbostock committed Dec 20, 2012
View
2 test/core/json-test.js
@@ -9,7 +9,7 @@ suite.addBatch({
"json": {
topic: function() {
var cb = this.callback;
- d3.json("examples/data/sample.json", function(error, json) {
+ d3.json("test/data/sample.json", function(error, json) {
cb(null, json);
});
},
View
4 test/core/text-test.js
@@ -9,7 +9,7 @@ suite.addBatch({
"text": {
topic: function() {
var cb = this.callback;
- d3.text("examples/data/sample.txt", function(error, text) {
+ d3.text("test/data/sample.txt", function(error, text) {
cb(null, text);
});
},
@@ -22,7 +22,7 @@ suite.addBatch({
"": {
topic: function() {
var cb = this.callback;
- d3.text("examples/data/sample.txt", "text/plain+sample", function(error, text) {
+ d3.text("test/data/sample.txt", "text/plain+sample", function(error, text) {
cb(null, text);
});
},
View
6 test/core/xhr-test.js
@@ -9,12 +9,12 @@ suite.addBatch({
"xhr": {
topic: function() {
var cb = this.callback;
- d3.xhr("examples/data/sample.txt", function(error, req) {
+ d3.xhr("test/data/sample.txt", function(error, req) {
cb(null, req);
});
},
"makes an asynchronous HTTP request": function(req) {
- assert.equal(req._info.url, "examples/data/sample.txt");
+ assert.equal(req._info.url, "test/data/sample.txt");
assert.isTrue(req._info.async);
},
"invokes the callback with the request object": function(req) {
@@ -30,7 +30,7 @@ suite.addBatch({
"": {
topic: function() {
var cb = this.callback;
- d3.xhr("examples/data/sample.txt", "text/plain", function(error, req) {
+ d3.xhr("test/data/sample.txt", "text/plain", function(error, req) {
cb(null, req);
});
},
View
4 test/core/xml-test.js
@@ -9,7 +9,7 @@ suite.addBatch({
"xml": {
topic: function() {
var cb = this.callback;
- d3.xml("examples/data/sample.xml", function(error, xml) {
+ d3.xml("test/data/sample.xml", function(error, xml) {
cb(null, xml);
});
},
@@ -22,7 +22,7 @@ suite.addBatch({
"": {
topic: function() {
var cb = this.callback;
- d3.xml("examples/data/sample.txt", "application/xml+sample", function(error, xml) {
+ d3.xml("test/data/sample.txt", "application/xml+sample", function(error, xml) {
cb(null, xml);
});
},
View
2 test/data/sample.csv
@@ -0,0 +1,2 @@
+Hello,World
+42,"""fish"""
View
1 test/data/sample.json
@@ -0,0 +1 @@
+[{"Hello": 42, "World": "\"fish\""}]
View
2 test/data/sample.tsv
@@ -0,0 +1,2 @@
+Hello World
+42 """fish"""
View
1 test/data/sample.txt
@@ -0,0 +1 @@
+Hello, world!
View
4 test/data/sample.xml
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<hello>
+ <world name="Earth"/>
+</hello>
View
2 test/dsv/csv-test.js
@@ -9,7 +9,7 @@ suite.addBatch({
"csv": {
topic: function() {
var cb = this.callback;
- d3.csv("examples/data/sample.csv", function(error, csv) {
+ d3.csv("test/data/sample.csv", function(error, csv) {
cb(null, csv);
});
},
View
2 test/dsv/tsv-test.js
@@ -9,7 +9,7 @@ suite.addBatch({
"tsv": {
topic: function() {
var cb = this.callback;
- d3.tsv("examples/data/sample.tsv", function(error, tsv) {
+ d3.tsv("test/data/sample.tsv", function(error, tsv) {
cb(null, tsv);
});
},

0 comments on commit abaa6f1

Please sign in to comment.