Add an X-Cache-Channel header to all GET requests. Closes #53.

This commit is contained in:
Sandro Santilli
2012-09-25 09:27:03 +02:00
parent 446627e305
commit bc506784ca
3 changed files with 36 additions and 15 deletions
+5 -2
View File
@@ -40,6 +40,7 @@ suite('server', function() {
method: 'GET'
},{
status: 200,
headers: { 'X-Cache-Channel': 'cartodb_test_user_1_db:my_table' },
body: '{"style":"#my_table {marker-fill: #FF6600;marker-opacity: 1;marker-width: 8;marker-line-color: white;marker-line-width: 3;marker-line-opacity: 0.9;marker-placement: point;marker-type: ellipse;marker-allow-overlap: true;}"}'
}, function() { done(); });
});
@@ -261,6 +262,7 @@ suite('server', function() {
method: 'GET'
},{
status: 200,
headers: { 'X-Cache-Channel': 'cartodb_test_user_1_db:my_tablez' },
body: '{"infowindow":null}'
}, function() { done(); });
});
@@ -326,7 +328,8 @@ suite('server', function() {
method: 'GET'
},{
status: 200,
headers: { 'Content-Type': 'text/javascript; charset=utf-8; charset=utf-8' }
headers: { 'Content-Type': 'text/javascript; charset=utf-8; charset=utf-8',
'X-Cache-Channel': 'cartodb_test_user_1_db:gadm4' }
}, function() { done(); });
});
@@ -391,7 +394,7 @@ suite('server', function() {
method: 'GET'
},{
status: 200,
headers: { 'Content-Type': 'image/png' }
headers: { 'Content-Type': 'image/png', 'X-Cache-Channel': 'cartodb_test_user_1_db:gadm4' }
}, function() { done(); });
});