Class CommonsTestingUtil

java.lang.Object
org.infinispan.commons.test.CommonsTestingUtil

public class CommonsTestingUtil extends Object
Since:
11.0
Author:
Tristan Tarrant <tristan@infinispan.org>
  • Field Details

  • Constructor Details

    • CommonsTestingUtil

      public CommonsTestingUtil()
  • Method Details

    • tmpDirectory

      public static String tmpDirectory(Class<?> test)
      Creates a path to a unique (per test) temporary directory. By default, the directory is created in the platform's temp directory, but the location can be overridden with the infinispan.test.tmpdir system property.
      Parameters:
      test - test that requires this directory.
      Returns:
      an absolute path
    • tmpDirectory

      public static String tmpDirectory(String... folders)
      Returns:
      an absolute path
    • tmpDirectory

      public static String tmpDirectory()
    • loadFileAsString

      public static String loadFileAsString(InputStream is) throws IOException
      Throws:
      IOException