code: private void checkSubArray(byte[] test, byte[] data, int offset) {
      Preconditions.checkArgument(data.length >= test.length + offset);
      for (int i = 0; i < test.length; i++) {
        Preconditions.checkArgument(test[i] == data[i + offset]);
      }
    }
docs: Checks that the "test" array is in the data array starting at the given offset.