Refactor test-client in order to use same interface for named and anonymous maps

This commit is contained in:
Daniel García Aubert
2017-04-26 18:27:18 +02:00
parent c481d6473c
commit 2f4e4246a4
2 changed files with 60 additions and 170 deletions
+2 -2
View File
@@ -196,13 +196,13 @@ describe('buffer size per format for named maps', function () {
testCases.forEach(function (test) {
it(test.desc, function (done) {
var testClient = new TestClient(undefined, 1234, test.template);
var testClient = new TestClient(test.template, 1234);
var coords = test.coords;
var options = {
format: test.format,
placeholders: test.placeholders
};
testClient.getNamedTile(coords.z, coords.x, coords.y, options, function (err, res, tile) {
testClient.getTile(coords.z, coords.x, coords.y, options, function (err, res, tile) {
assert.ifError(err);
// To generate images use:
//tile.save('./test/fixtures/buffer-size/tile-7.64.48-buffer-size-0-test.png');