Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions src/cmake/testing.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -103,9 +103,15 @@ macro (oiio_add_tests)
set (_test_disabled TRUE)
endif ()
endforeach ()
# For OCIO 2.2+, have the testsuite use the default built-in config
# Things we add to the environment for tests:
# - For OCIO 2.2+, have the testsuite use the default built-in config.
# - Some tests (e.g. cmake-consumer) configure their own child cmake
# project that does find_package(OpenImageIO). Point them at this
# build's install location so that works out of the box, without users
# needing to set OpenImageIO_ROOT in their environment themselves.
list (APPEND _ats_ENVIRONMENT "OCIO=ocio://default"
"OIIO_TESTSUITE_OCIOCONFIG=ocio://default")
"OIIO_TESTSUITE_OCIOCONFIG=ocio://default"
"OpenImageIO_ROOT=${CMAKE_INSTALL_PREFIX}")
if (_test_disabled)
message (STATUS "Skipping test(s) ${_ats_UNPARSED_ARGUMENTS} because of disabled ${_ats_ENABLEVAR}")
elseif (_test_notfound)
Expand Down
5 changes: 5 additions & 0 deletions testsuite/runtest.py
Original file line number Diff line number Diff line change
Expand Up @@ -426,6 +426,11 @@ def runtest (command: str, outputs: list[str], failureok: int=0) -> int :
print ("#### Error: this command failed: ", sub_command)
print ("FAIL")
err = 1
if os.path.isfile("build.txt") :
print ("--- BUILD LOG ---\n")
with open("build.txt", "r") as fbuild :
print (fbuild.read())
print ("--- END BUILD LOG ---\n")
Comment on lines +429 to +433

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm going to ignore this suggestion because for these couple of isolated tests, the build logs are short and the failures should be rare, and if they happen, we probably do want to see the full log.


for out in outputs :
(prefix, extension) = os.path.splitext(out)
Expand Down
Loading