Running FATE: Difference between revisions

From MultimediaWiki
Jump to navigation Jump to search
mNo edit summary
(→‎Get The Samples: Add ntoe about error with permissions)
Line 3: Line 3:

   rsync -WaL rsync:// /path/to/fate/samples
   rsync -WaL rsync:// /path/to/fate/samples
Please ignore any "Permission denied" errors, permissions are fixed regularly by a cron job.

== Configuration ==
== Configuration ==

Revision as of 04:22, 13 November 2010

Get The Samples

Sync the FATE samples:

 rsync -WaL rsync:// /path/to/fate/samples

Please ignore any "Permission denied" errors, permissions are fixed regularly by a cron job.


Create a configuration file setting the following variables:

slot=                                   # some unique identifier
repo=svn://         # the source repository
fate_recv="ssh"    # command to submit report

# the following are optional and map to configure options
extra_conf=     # extra configure options not covered above

make=           # name of GNU make if not 'make'
workdir=        # directory in which to do all the work

This file is parsed by the shell, so any shell features may be used. Any site-specific settings can be made here as well, such as PATH to compilers etc. One such file is required per configuration to be tested.

The $slot value can be anything not already in use. I have chosen names of the form arch-os-compiler-version for mine, and I suggest others follow a similar scheme. Allowed characters are alphanumeric, underscore, period, and hyphen.

Get the Script

Fetch the file 'tests/' from the ffmpeg repo. This script checks out the source, builds it, runs the tests, and submits the report to the server. I suggest you watch it for changes and update keep an up to date version, although I hope this file will be rather stable.

Test Run

Perform a test run by leaving $fate_recv unset in the configuration and issue the command " /path/to/config/file". This should perform all the steps except the final report submission. In the end, $workdir should contain the following files:

  • configure.log
  • compile.log
  • test.log
  • report
  • version

After a successful run, the 'report' file should contain one line for each test and a couple of header lines. Most of the content is base64-encoded, so it will look like gibberish.

If any of the files are missing, or if the report seems too sparse, check for errors that may have occurred.

Delete the version file to force a retest of the same revision.

Submitting Resuts

When everything is working properly, create and ssh key, send it to the FATE system adminstrator, and await confirmation. Make sure the ssh command used in the fate_recv setting uses this key for authentication. You will also need to accept the host key of the server. It's fingerprint is


Accepting the host key is most easily done by running the ssh command directly from a shell once. When it connects, simply kill it. You will not get a shell prompt.

Regular Cycles

You are now ready to commence automated testing. Set up a cron job, shell script, or use whatever means you prefer to run the command from step 3 at regular intervals. If using multiple configurations, a simple shell wrapper iterating over them may be convenient.

The script will refuse to run if the workdir is locked by the presence of a fate.lock file there. If something dies leaving this file behind, you must delete it manually.

Adjunct to running the FATE script from cron, it's also useful to rsync the FATE samples directory via cron. This doesn't need to be performed as frequently. Once per day is adequate.