Batch merge for rc2 of 2.7. 'svn merge -r7967:HEAD from trunk (Closes #1733) (Closes #1489) (Closes #1639) (Closes #1718) (Closes #1723) (Closes #1732) (Closes #1616) (Closes #1722)
git-svn-id: http://svn.openlayers.org/branches/openlayers/2.7@8012 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -102,6 +102,35 @@
|
||||
};
|
||||
|
||||
var resp = protocol.read(readOptions);
|
||||
|
||||
OpenLayers.Request.GET = _get;
|
||||
}
|
||||
|
||||
function test_read_bbox(t) {
|
||||
t.plan(1);
|
||||
var protocol = new OpenLayers.Protocol.HTTP();
|
||||
|
||||
// fake XHR request object
|
||||
var request = {'status': 200};
|
||||
|
||||
var _get = OpenLayers.Request.GET;
|
||||
|
||||
var bounds = new OpenLayers.Bounds(1, 2, 3, 4);
|
||||
var filter = new OpenLayers.Filter.Spatial({
|
||||
type: OpenLayers.Filter.Spatial.BBOX,
|
||||
value: bounds,
|
||||
projection: "foo"
|
||||
});
|
||||
|
||||
OpenLayers.Request.GET = function(options) {
|
||||
t.eq(options.params['bbox'].toString(), bounds.toArray().toString(),
|
||||
'GET called with bbox filter in params');
|
||||
return request;
|
||||
};
|
||||
|
||||
var resp = protocol.read({filter: filter});
|
||||
|
||||
OpenLayers.Request.GET = _get;
|
||||
}
|
||||
|
||||
function test_parseFeatures(t) {
|
||||
@@ -217,6 +246,8 @@
|
||||
};
|
||||
|
||||
var resp = protocol.create(features, createOptions);
|
||||
|
||||
OpenLayers.Request.POST = _post;
|
||||
}
|
||||
|
||||
function test_update(t) {
|
||||
@@ -284,8 +315,10 @@
|
||||
};
|
||||
|
||||
var resp = protocol.update(feature, updateOptions);
|
||||
|
||||
|
||||
OpenLayers.Request.PUT = _put;
|
||||
}
|
||||
|
||||
function test_handleResponse(t) {
|
||||
t.plan(6);
|
||||
|
||||
@@ -404,6 +437,7 @@
|
||||
|
||||
var resp = protocol['delete'](feature, deleteOptions);
|
||||
|
||||
OpenLayers.Request.DELETE = _delete;
|
||||
}
|
||||
|
||||
function test_handleDelete(t) {
|
||||
|
||||
Reference in New Issue
Block a user