"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "googletest/test/googletest-output-test.py" between
googletest-release-1.10.0.tar.gz and googletest-release-1.11.0.tar.gz

About: GoogleTest is Google's (unit) testing and mocking framework for C++ tests.

googletest-output-test.py  (googletest-release-1.10.0):googletest-output-test.py  (googletest-release-1.11.0)
skipping to change at line 32 skipping to change at line 32
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
"""Tests the text output of Google C++ Testing and Mocking Framework. r"""Tests the text output of Google C++ Testing and Mocking Framework.
To update the golden file: To update the golden file:
googletest_output_test.py --build_dir=BUILD/DIR --gengolden googletest_output_test.py --build_dir=BUILD/DIR --gengolden
where BUILD/DIR contains the built googletest-output-test_ file. where BUILD/DIR contains the built googletest-output-test_ file.
googletest_output_test.py --gengolden googletest_output_test.py --gengolden
googletest_output_test.py googletest_output_test.py
""" """
import difflib import difflib
import os import os
skipping to change at line 318 skipping to change at line 318
if __name__ == '__main__': if __name__ == '__main__':
if NO_STACKTRACE_SUPPORT_FLAG in sys.argv: if NO_STACKTRACE_SUPPORT_FLAG in sys.argv:
# unittest.main() can't handle unknown flags # unittest.main() can't handle unknown flags
sys.argv.remove(NO_STACKTRACE_SUPPORT_FLAG) sys.argv.remove(NO_STACKTRACE_SUPPORT_FLAG)
if GENGOLDEN_FLAG in sys.argv: if GENGOLDEN_FLAG in sys.argv:
if CAN_GENERATE_GOLDEN_FILE: if CAN_GENERATE_GOLDEN_FILE:
output = GetOutputOfAllCommands() output = GetOutputOfAllCommands()
golden_file = open(GOLDEN_PATH, 'wb') golden_file = open(GOLDEN_PATH, 'wb')
golden_file.write(output) golden_file.write(output.encode())
golden_file.close() golden_file.close()
else: else:
message = ( message = (
"""Unable to write a golden file when compiled in an environment """Unable to write a golden file when compiled in an environment
that does not support all the required features (death tests, that does not support all the required features (death tests,
typed tests, stack traces, and multiple threads). typed tests, stack traces, and multiple threads).
Please build this test and generate the golden file using Blaze on Linux.""") Please build this test and generate the golden file using Blaze on Linux.""")
sys.stderr.write(message) sys.stderr.write(message)
sys.exit(1) sys.exit(1)
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)