|
|
|
@ -41,14 +41,22 @@ describe('components/modals/export-data/modal-export-data-view', function () {
|
|
|
|
|
expect(this.view.$('[data-format=csv]:checked').length).toBe(1);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
it('should render properly for lines', function () {
|
|
|
|
|
this.queryGeometryModel.set('simple_geom', 'line');
|
|
|
|
|
this.view.render();
|
|
|
|
|
|
|
|
|
|
expect(this.view.$('.Modal-listFormItem').length).toBe(5);
|
|
|
|
|
expect(this.view.$('.Modal-listFormItem.is-disabled').length).toBe(0);
|
|
|
|
|
expect(this.view.$('[data-format=csv]:checked').length).toBe(1);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
it('should render properly for polygons', function () {
|
|
|
|
|
this.queryGeometryModel.set('simple_geom', 'polygon');
|
|
|
|
|
this.view.render();
|
|
|
|
|
|
|
|
|
|
expect(this.view.$('.Modal-listFormItem').length).toBe(5);
|
|
|
|
|
expect(this.view.$('.Modal-listFormItem.is-disabled').length).toBe(1);
|
|
|
|
|
expect(this.view.$('[data-format=csv]:checked').length).toBe(0);
|
|
|
|
|
expect(this.view.$('[data-format=shp]:checked').length).toBe(1);
|
|
|
|
|
expect(this.view.$('.Modal-listFormItem.is-disabled').length).toBe(0);
|
|
|
|
|
expect(this.view.$('[data-format=csv]:checked').length).toBe(1);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
it('should render properly for no geometries', function () {
|
|
|
|
|