Fix broken tests due to missing sample data.
This commit is contained in:
Родитель
7a67b00b3e
Коммит
abaa6f1645
|
@ -9,7 +9,7 @@ suite.addBatch({
|
||||||
"json": {
|
"json": {
|
||||||
topic: function() {
|
topic: function() {
|
||||||
var cb = this.callback;
|
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);
|
cb(null, json);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
@ -9,7 +9,7 @@ suite.addBatch({
|
||||||
"text": {
|
"text": {
|
||||||
topic: function() {
|
topic: function() {
|
||||||
var cb = this.callback;
|
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);
|
cb(null, text);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -22,7 +22,7 @@ suite.addBatch({
|
||||||
"": {
|
"": {
|
||||||
topic: function() {
|
topic: function() {
|
||||||
var cb = this.callback;
|
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);
|
cb(null, text);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
@ -9,12 +9,12 @@ suite.addBatch({
|
||||||
"xhr": {
|
"xhr": {
|
||||||
topic: function() {
|
topic: function() {
|
||||||
var cb = this.callback;
|
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);
|
cb(null, req);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
"makes an asynchronous HTTP request": function(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);
|
assert.isTrue(req._info.async);
|
||||||
},
|
},
|
||||||
"invokes the callback with the request object": function(req) {
|
"invokes the callback with the request object": function(req) {
|
||||||
|
@ -30,7 +30,7 @@ suite.addBatch({
|
||||||
"": {
|
"": {
|
||||||
topic: function() {
|
topic: function() {
|
||||||
var cb = this.callback;
|
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);
|
cb(null, req);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
@ -9,7 +9,7 @@ suite.addBatch({
|
||||||
"xml": {
|
"xml": {
|
||||||
topic: function() {
|
topic: function() {
|
||||||
var cb = this.callback;
|
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);
|
cb(null, xml);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
@ -22,7 +22,7 @@ suite.addBatch({
|
||||||
"": {
|
"": {
|
||||||
topic: function() {
|
topic: function() {
|
||||||
var cb = this.callback;
|
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);
|
cb(null, xml);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
Hello,World
|
||||||
|
42,"""fish"""
|
|
|
@ -0,0 +1 @@
|
||||||
|
[{"Hello": 42, "World": "\"fish\""}]
|
|
@ -0,0 +1,2 @@
|
||||||
|
Hello World
|
||||||
|
42 """fish"""
|
|
|
@ -0,0 +1 @@
|
||||||
|
Hello, world!
|
|
@ -0,0 +1,4 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<hello>
|
||||||
|
<world name="Earth"/>
|
||||||
|
</hello>
|
|
@ -9,7 +9,7 @@ suite.addBatch({
|
||||||
"csv": {
|
"csv": {
|
||||||
topic: function() {
|
topic: function() {
|
||||||
var cb = this.callback;
|
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);
|
cb(null, csv);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
@ -9,7 +9,7 @@ suite.addBatch({
|
||||||
"tsv": {
|
"tsv": {
|
||||||
topic: function() {
|
topic: function() {
|
||||||
var cb = this.callback;
|
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);
|
cb(null, tsv);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
Загрузка…
Ссылка в новой задаче