Structs

  • | A wrapper that allows injection of errors. |
  • | An instance of Tester is allocated to | hold temporary state during the execution | of an assertion. |

Functions

  • | Store in dst a string of length “len” that | will compress to “Ncompressed_fraction” bytes | and return a Slice that references the | generated data.
  • | Return a random key with the specified | length that may contain interesting | characters (e.g. \x00, \xff, etc.). |
  • | Return a randomization seed for this run. | Typically returns the same number on repeated | invocations of this binary, but automated runs | may be able to vary the seed.
  • | Store in *dst a random string of length | “len” and return a Slice that references | the generated data. |
  • | Register the specified test. Typically | not used directly, but invoked via the | macro expansion of TEST. |
  • | Run some of the tests registered by the TEST() | macro. If the environment variable | “LEVELDB_TESTS” is not set, runs all tests. | | Otherwise, runs only the tests whose name | contains the value of “LEVELDB_TESTS” as | a substring. E.g., suppose the tests are: | | TEST(Foo, Hello) { … } | TEST(Foo, World) { … } | | LEVELDB_TESTS=Hello will run the first test | LEVELDB_TESTS=o will run both tests | LEVELDB_TESTS=Junk will run no tests | | Returns 0 if all tests pass. | | Dies or returns a non-zero value if some test | fails.
  • | Return the directory to use for temporary | storage. |