Class TimeoutUtil

java.lang.Object
org.jboss.resteasy.utils.TimeoutUtil

public class TimeoutUtil extends Object
This class is copied from shared module of wildfly-core testsuite.

Adjusts default timeouts according to the system property.

All tests influenced by machine slowness should employ this util.

Author:
Ondrej Zizka, Radoslav Husar, Jan Lanik
  • Field Details

  • Constructor Details

    • TimeoutUtil

      public TimeoutUtil()
  • Method Details

    • adjust

      public static int adjust(int amount)
      Adjusts timeout for operations.
      Returns:
      given timeout adjusted by ratio from system property "ts.timeout.factor"
    • getFactor

      public static double getFactor()
      Get timeout factor to multiply by.
      Returns:
      double factor value
    • getRawFactor

      public static int getRawFactor()
      Get raw timeout factor.
      Returns:
      value of parsed system property "ts.timeout.factor"