Add support for writing Native

This commit is contained in:
Bart van den Eijnden
2014-03-10 15:24:00 +01:00
parent 4e5e75f525
commit 33abbfced1
3 changed files with 58 additions and 4 deletions

View File

@@ -234,6 +234,31 @@ describe('ol.format.WFS', function() {
});
describe('when writing out a Transaction request', function() {
var text;
before(function(done) {
afterLoadText('spec/ol/format/wfs/Native.xml', function(xml) {
text = xml;
done();
});
});
it('handles writing out Native', function() {
var format = new ol.format.WFS();
var serialized = format.writeTransaction(null, null, null, {
nativeElements: [{
vendorId: 'ORACLE',
safeToIgnore: true,
value: 'ALTER SESSION ENABLE PARALLEL DML'
}, {
vendorId: 'ORACLE',
safeToIgnore: false,
value: 'Another native line goes here'
}]
});
expect(serialized).to.xmleql(ol.xml.load(text));
});
});
});