Can ctest be run on read only file system

It seems that this file is only cared about if something went wrong. It seems that --output-on-failure will suppress this behavior. Does that flag work?