1. 27 May, 2016 1 commit
    • Olivier Berthier's avatar
      framework: Add aborting option when a monitored error is detected · 21031482
      Olivier Berthier authored
      This adds a policy which advises when the user should reboot the system
      to avoid noisy test results due to system becoming unstable, for
      instance, and therefore continues testing successfully.
      To do this, a new module is proposed. A class Monitoring is used for
      managing the monitoring rules. Two types of rules, MonitoringFile and
      MonitoringLinuxDmesg, derived from the abstract class MonitoringBase,
      have been implemented. The first allow to track a pattern on standard
      files or locked files. The second, derived from dmesg.LinuxDmesg, will
      track a pattern on the dmesg.
      The monitoring rules must be defined in piglit.conf at the section
      monitored-errors. If one of the regex is found, Piglit will raise a
      PiglitAbort exception, stop the test execution -terminating test thread
      pool- and exit with code 3.
      Then test execution resume, after rebooting the system or not, is done
      like usually with command line parameter "resume".
      To call it, use command line parameter: --abort-on-monitored-error
      This option implies --no-concurrent
      This include also a set of unit tests for this module.
      Reviewed-by: default avatarDylan Baker <dylanx.c.baker@intel.com>
  2. 17 Apr, 2016 1 commit
  3. 11 Feb, 2016 1 commit
    • Dylan Baker's avatar
      python: function with six version 1.5.2 · c4a5618a
      Dylan Baker authored
      CMake actually marks that we require six 1.4.0, however, I can't find
      any packages anywhere for 1.4.0, and the lowest version I've seen
      requested is 1.5.2.
      This fixes requirements for working with six 1.5.2, and sets tox to use
      1.5.2 (and a suitable version of mock). Primarily there are a few things
      we're using that are not available: six.moves.getcwd, six.viewvalues,
      Signed-off-by: default avatarDylan Baker <dylanx.c.baker@intel.com>
      Tested-by: Brian Paul's avatarBrian Paul <brianp@vmware.com>
  4. 08 Feb, 2016 1 commit
  5. 22 Dec, 2015 1 commit
    • Dylan Baker's avatar
      framework/exceptions.py: Drop PIGLIT_DEBUG · 4d2172bf
      Dylan Baker authored
      Previously a stack trace would be suppressed in all instances unless
      the PIGLIT_DEBUG environment variable was truthy. This was suboptimal
      for a number of reasons.
      This patch removes that functionality, now only a subset of piglit
      specific exceptions that are meant to be suppressed are. All other
      exceptions are directly raised, stopping the runner immediately. Other
      piglit specific exceptions have been extended to have custom error
      messages rather than relying on the handler to add them.
      v2: - remove unit tests that no longer apply
      Reviewed-by: Jose Fonseca <jfonseca@vmware.com> (v1)
      Signed-off-by: default avatarDylan Baker <dylanx.c.baker@intel.com>
  6. 06 Jul, 2015 1 commit
    • Dylan Baker's avatar
      framework: Re-raise uncaught exceptions from their original context · 8b75dd6e
      Dylan Baker authored
      When an uncaught exception reaches the top level exception handler, and
      PIGLIT_DEBUG is true, then the exception will be re-raised. The problem
      is that currently the exception is re-raised as 'raise e', which raise
      the correct exception, but does so from the wrong context, making the
      back-trace completely useless. By re-raising by simply using the 'raise'
      keyword causes the exception to be passed on 'as-is', making the back
      trace useful for debugging.
      Signed-off-by: default avatarDylan Baker <dylanx.c.baker@intel.com>
  7. 09 Jun, 2015 1 commit
  8. 19 May, 2015 1 commit
    • Dylan Baker's avatar
      framework/exceptions.py: add a new module for unified piglit exceptions · e1515d58
      Dylan Baker authored
      This is the basis of providing clean, unified exception handling to
      piglit, this provides a set of Exception classes and a function
      decorator to be used on main functions. Together these provide well
      formatted error messages that differentiate between expected failures
      and unexpected failures and provide clean, readable error messages.
      The goal is that this will give us the ability to get clean errors when
      they are expected, and the ability to hide stack traces when they're
      Stack traces for unexpected errors can be turned back on by setting the
      PIGLIT_DEBUG environment variable
      Signed-off-by: default avatarDylan Baker <dylanx.c.baker@intel.com>