astropy/astropy — pull request #713 by eteq (2013-02-01 07:22:08+00:00)
Title: Add doc build to travis

This was prompted by #704 and the occasional commit to master I've been doing to eliminate sphinx build warnings that sneak into master because people either forget to run sphinx on their PRs or make some change after they run sphinx and forget to do so again.

This adds another job to travis that builds the documentation, and reports as failing if warnings appear in the doc build. The documentation this builds is not available to view after the build finishes, but at least this will catch typos that lead to sphinx warnings.

To do this I had to add an additional option to ``python setup.py build_sphinx`` that causes the build to give a return code of 1 if the sphinx build has warnings. I don't imagine anyone will want to use this for anything but Travis, but you never know.

An example of a *failed* doc build (specifically, the failures from before #704 can be found at https://travis-ci.org/eteq/astropy/jobs/4511888 , while a successful build (made from merging this into master with some small tweaks to make the build go faster) looks like https://travis-ci.org/eteq/astropy/jobs/4511876