You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

148 lines
4.6KB

  1. \input texinfo @c -*- texinfo -*-
  2. @settitle FATE Automated Testing Environment
  3. @titlepage
  4. @center @titlefont{FATE Automated Testing Environment}
  5. @end titlepage
  6. @top
  7. @contents
  8. @chapter Introduction
  9. FATE provides a regression testsuite embedded within the Libav build system.
  10. It can be run locally and optionally configured to send reports to a web
  11. aggregator and viewer @url{http://fate.libav.org}.
  12. It is advised to run FATE before submitting patches to the current codebase
  13. and provide new tests when submitting patches to add additional features.
  14. @chapter Running FATE
  15. @section Samples and References
  16. In order to run, FATE needs a large amount of data (samples and references)
  17. that is provided separately from the actual source distribution.
  18. To inform the build system about the testsuite location, pass
  19. @option{--samples=<path to the samples>} to @command{configure} or set the
  20. @var{SAMPLES} Make variable or the @var{LIBAV_SAMPLES} environment variable
  21. to a suitable value.
  22. To use a custom wrapper to run the test, pass @option{--target-exec} to
  23. @command{configure} or set the @var{TARGET_EXEC} Make variable.
  24. The dataset is available through @command{rsync}, is possible to fetch
  25. the current sample using the straight rsync command or through a specific
  26. @ref{Makefile target}.
  27. @example
  28. # rsync -aL rsync://fate-suite.libav.org/fate-suite/ fate-suite
  29. @end example
  30. @example
  31. # make fate-rsync SAMPLES=fate-suite
  32. @end example
  33. @chapter Manual Run
  34. FATE regression test can be run through @command{make}.
  35. Specific Makefile targets and Makefile variables are available:
  36. @anchor{Makefile target}
  37. @section FATE Makefile targets
  38. @table @option
  39. @item fate-list
  40. List all fate/regression test targets.
  41. @item fate-rsync
  42. Shortcut to download the fate test samples to the specified testsuite location.
  43. @item fate
  44. Run the FATE test suite (requires the fate-suite dataset).
  45. @end table
  46. @section FATE Makefile variables
  47. @table @option
  48. @item V
  49. Verbosity level, can be set to 0, 1 or 2.
  50. @table @option
  51. @item 0
  52. show just the test arguments
  53. @item 1
  54. show just the command used in the test
  55. @item 2
  56. show everything
  57. @end table
  58. @item SAMPLES
  59. Specify or override the path to the FATE samples at make time, it has a
  60. meaning only while running the regression tests.
  61. @item THREADS
  62. Specify how many threads to use while running regression tests, it is
  63. quite useful to detect thread-related regressions.
  64. @item CPUFLAGS
  65. Specify a mask to be applied to autodetected CPU flags.
  66. @item TARGET_EXEC
  67. Specify or override the wrapper used to run the tests.
  68. @end table
  69. @example
  70. make V=1 SAMPLES=/var/fate/samples THREADS=2 CPUFLAGS=mmx fate
  71. @end example
  72. @chapter Automated Tests
  73. In order to automatically testing specific configurations, e.g. multiple
  74. compilers, @command{tests/fate.sh} is provided.
  75. This shell script builds Libav, runs the regression tests and prepares
  76. a report that can be sent to @url{http://fate.libav.org/} or directly
  77. examined locally.
  78. @section Testing Profiles
  79. The configuration file passed to @command{fate.sh} is shell scripts as well.
  80. It must provide at least a @var{slot} identifier, the @var{repo} from
  81. which fetch the sources, the @var{samples} directory, a @var{workdir} with
  82. enough space to build and run all the tests.
  83. Optional submit command @var{fate_recv} and a @var{comment} to describe
  84. the testing profile are available.
  85. Additional optional parameter to tune the Libav building and reporting process
  86. can be passed.
  87. @example
  88. slot= # some unique identifier
  89. repo=git://git.libav.org/libav.git # the source repository
  90. samples=/path/to/fate/samples
  91. workdir= # directory in which to do all the work
  92. fate_recv="ssh -T fate@@fate.libav.org" # command to submit report
  93. comment= # optional description
  94. # the following are optional and map to configure options
  95. arch=
  96. cpu=
  97. cross_prefix=
  98. cc=
  99. target_os=
  100. sysroot=
  101. target_exec=
  102. target_path=
  103. extra_cflags=
  104. extra_ldflags=
  105. extra_libs=
  106. extra_conf= # extra configure options not covered above
  107. #make= # name of GNU make if not 'make'
  108. makeopts= # extra options passed to 'make'
  109. #tar= # command to create a tar archive from its arguments on
  110. # stdout, defaults to 'tar c'
  111. @end example
  112. @section Special Instances
  113. The @var{TARGET_EXEC} option provides a way to run FATE wrapped in
  114. @command{valgrind}, @command{qemu-user} or @command{wine} or on remote targets
  115. through @command{ssh}.
  116. @section Submitting Reports
  117. In order to send reports you need to create an @command{ssh} key and send it
  118. to @email{root@@libav.org}.
  119. The current server fingerprint is @var{a4:99:d7:d3:1c:92:0d:56:d6:d5:61:be:01:ae:7d:e6}