Fabric build scripts and Nightwatch test Reports
2 April 2019
I’ve just started some work on a fabric script that works as part of a build process.
The actual script is part of a long process, and I’m not familiar with fabric (or even python) so I spent a little time cooking a basic script that does a few things I need.
- Hello world stuff just to check I understand the syntax
- Define a remote host which is a local vagrant instance
- Run some tests
- Copy to the local server any test reports (even if the tests fail)
- Return a failure result if tests fail
I wasn’t quite sure how nightwatch returned when tests run OK but fail - it seems it returnd an error status in this case. So I needed to handle this, grab the results, and then re-throw the error condition.
Working in a small script really helps speed up work, and now I shouldn’t have much left to do when I integrate this with teh main build scripts.
Though I’ve tried to build html reports from the nightwatch output and so far haven’t succeeded.
|
|