Re: [Qgis-user] Is there a way to create automated tests inside my own processing models?

2018-07-09 Thread Jonathan Moules

Hi Carlos,

I think that's an excellent (implied) suggestion.

I know that FME has basically no frame-work for testing "workspaces" 
(FME's equivalent of QGIS' "models") which makes development somewhat 
hap-hazard. If QGIS had one, it would certainly be a leg-up over the 
industry leader in this area. Last time I used it ArcGIS didn't either, 
but that was quite a while ago.


To answer the question - I believe at present with QGIS (and ArcGIS 
too), you could export the model to Python and then do conventional 
unit-tests that way. But it's a clunky way of doing it.


To me at least this seems like it would be well suited to being added to 
QGIS. It's not "sexy", but it's definitely useful.


Cheers,

Jonathan



On 2018-07-04 07:55, Carlos Cámara wrote:

Dear all,

I am just starting with QGIS' processing to create some complex model 
which makes quite a lot of changes and I would like to know if there 
is a way to test my own model while launching it, so if the tests 
fail, I can get a notification and I will know that something went 
wrong before I realize too late and I have to lose any changes I made 
after executing the model with unexpected results.


*Example*:

I am doing several joins and spatial joins. I learnt the hard way that 
after triggering several times my model, every time I was joining 
layers, new fields were added with a |_1| appended to them in order 
not to overwrite the previously created fields by mistake when I 
repeated the model. It would be great to have some test that either 
checked all the layer's fields or counted its number and, if they 
weren't as expected, triggered an alarm/dialog box or created a log file.


Regards


Carlos Cámara
http://carloscamara.es


___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

[Qgis-user] Is there a way to create automated tests inside my own processing models?

2018-07-03 Thread Carlos Cámara
Dear all,

I am just starting with QGIS' processing to create some complex model which
makes quite a lot of changes and I would like to know if there is a way to
test my own model while launching it, so if the tests fail, I can get a
notification and I will know that something went wrong before I realize too
late and I have to lose any changes I made after executing the model with
unexpected results.

*Example*:

I am doing several joins and spatial joins. I learnt the hard way that
after triggering several times my model, every time I was joining layers,
new fields were added with a _1 appended to them in order not to overwrite
the previously created fields by mistake when I repeated the model. It
would be great to have some test that either checked all the layer's fields
or counted its number and, if they weren't as expected, triggered an
alarm/dialog box or created a log file.
Regards


Carlos Cámara
http://carloscamara.es
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user