-
Notifications
You must be signed in to change notification settings - Fork 116
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Behat doc testing #1
Comments
Interesting idea :) A big issue that I see here is that Behat tests are, while very precise, not necessarily easy to read. They serve as specification, so that's fine. Documentation, on the other hand, serves as learning resource. Readability and understandability should be key there. I don't think we can achieve that with Behat tests. Second, Behat tests require changes to the FeatureContext every time a sentence is reworded. This would slow down work on the documentation considerably. Apart from this issue, I think that starting to write Behat tests for Sulu is a great idea. |
Well, I think (I had to check) the idea of the extension is to embed the behat sentences in the RST file, but they would not be rendered in the documentation. So they are essentially static and invisible. |
btw. we are already using Behat to test Sulu Standard, but the tests are quite flaky IIRC due to Husky/JS. |
@dantleech Would not even say that this is caused by Husky or JS, I am sure quite often we are not waiting for the right events to happen. If we write at some points only And apart from that it might not even be necessary to test this kind of stuff using behat. We could simply take the commands written, execute all of them, and see if we have a working sulu installation at the end. However, this is probably not as easy as it sounds 😕 |
On Thu, Mar 10, 2016 at 08:28:58AM -0800, Daniel Rotter wrote:
The point is there are no events we can listen to to say "OK" this is
Behat was just a tool that could be used to execute the generated file. This is also not about executing (and testing) commands, but also code |
I would really like to test out my idea of functional testing documentation with Sulu. (https://github.com/dantleech/sphinx-behat)
A prerequisite for this would be to make the documentations in RestructuredText format and use Sphinx (as with the symfony, doctrine and CMF docs).
A start might be to implement the installation instructions.
Functional testing the documentation would provide an additional smoke test and ensure that the documentation is always "working".
The text was updated successfully, but these errors were encountered: