Running ‘add-force.R’ [0s/0s]
  Running ‘bare_repository.R’ [0s/1s]
  Running ‘blame.R’ [0s/1s]
  Running ‘blob.R’ [0s/1s]
  Running ‘branch.R’ [0s/1s]
  Running ‘checkout-named-branch.R’ [0s/1s]
  Running ‘checkout.R’ [0s/1s]
  Running ‘checkout_branch.R’ [0s/1s]
  Running ‘checkout_commit.R’ [0s/0s]
  Running ‘checkout_tag.R’ [0s/1s]
  Running ‘clone_bare.R’ [0s/1s]
  Running ‘clone_branch.R’ [0s/1s]
  Running ‘clone_checkout.R’ [0s/1s]
  Running ‘commit.R’ [1s/1s]
  Running ‘config.R’ [0s/1s]
  Running ‘diff.R’ [0s/1s]
  Running ‘fast_forward_merge.R’ [0s/1s]
  Running ‘fetch.R’ [0s/1s]
  Running ‘graph.R’ [0s/1s]
  Running ‘index.R’ [0s/1s]
  Running ‘invalid-conf-var.R’ [0s/0s]
  Running ‘libgit2.R’ [0s/1s]
  Running ‘merge.R’ [0s/1s]
  Running ‘merge_named_branch.R’ [0s/1s]
  Running ‘normal_merge.R’ [0s/1s]
  Running ‘note.R’ [0s/0s]
  Running ‘odb_blobs.R’ [0s/0s]
  Running ‘pre-process-path.R’ [0s/1s]
  Running ‘pull.R’ [0s/1s]
  Running ‘push-force.R’ [0s/1s]
  Running ‘push.R’ [0s/1s]
  Running ‘reference.R’ [0s/1s]
  Running ‘reflog.R’ [0s/0s]
  Running ‘refspec.R’ [0s/1s]
  Running ‘remotes.R’ [0s/0s]
  Running ‘remove.R’ [0s/0s]
  Running ‘repository.R’ [0s/0s]
  Running ‘reset.R’ [0s/0s]
  Running ‘revparse.R’ [0s/1s]
  Running ‘signature.R’ [0s/0s]
  Running ‘stash.R’ [0s/1s]
  Running ‘status.R’ [0s/1s]
  Running ‘tag.R’ [0s/1s]
  Running ‘time.R’ [0s/1s]
  Running ‘tree.R’ [0s/0s]
  Running ‘when.R’ [0s/0s]
Running the tests in ‘tests/blob.R’ failed.
Complete output:
  > ## git2r, R bindings to the libgit2 library.
  > ## Copyright (C) 2013-2018 The git2r contributors
  > ##
  > ## This program is free software; you can redistribute it and/or modify
  > ## it under the terms of the GNU General Public License, version 2,
  > ## as published by the Free Software Foundation.
  > ##
  > ## git2r is distributed in the hope that it will be useful,
  > ## but WITHOUT ANY WARRANTY; without even the implied warranty of
  > ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  > ## GNU General Public License for more details.
  > ##
  > ## You should have received a copy of the GNU General Public License along
  > ## with this program; if not, write to the Free Software Foundation, Inc.,
  > ## 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
  > 
  > library("git2r")
  > 
  > ## For debugging
  > sessionInfo()
  R Under development (unstable) (2018-12-11 r75837)
  Platform: x86_64-pc-linux-gnu (64-bit)
  Running under: Debian GNU/Linux buster/sid
  
  Matrix products: default
  BLAS: /home/hornik/tmp/R.check/r-devel-clang/Work/build/lib/libRblas.so
  LAPACK: /home/hornik/tmp/R.check/r-devel-clang/Work/build/lib/libRlapack.so
  
  locale:
   [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
   [3] LC_TIME=en_US.UTF-8        LC_COLLATE=C              
   [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8   
   [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                 
   [9] LC_ADDRESS=C               LC_TELEPHONE=C            
  [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       
  
  attached base packages:
  [1] stats     graphics  grDevices utils     datasets  methods   base     
  
  other attached packages:
  [1] git2r_0.23.0
  
  loaded via a namespace (and not attached):
  [1] compiler_3.6.0
  > 
  > ## Create a directory in tempdir
  > path <- tempfile(pattern="git2r-")
  > dir.create(path)
  > 
  > ## Initialize a repository
  > repo <- init(path)
  > config(repo, user.name="Alice", user.email="alice@example.org")
  > 
  > ## Create a file
  > f <- file(file.path(path, "test.txt"), "wb")
  > writeChar("Hello world!\n", f, eos = NULL)
  > close(f)
  > 
  > ## add and commit
  > add(repo, "test.txt")
  > new_commit <- commit(repo, "Commit message")
  > 
  > ## Lookup blob
  > blob <- lookup(repo, "cd0875583aabe89ee197ea133980a9085d08e497")
  > stopifnot(isTRUE(is_blob(blob)))
  > stopifnot(identical(is_binary(blob), FALSE))
  > stopifnot(identical(blob, lookup(repo, "cd0875")))
  > stopifnot(identical(length(blob), 13L))
  > stopifnot(identical(content(blob), "Hello world!"))
  > blob
  blob:  cd0875583aabe89ee197ea133980a9085d08e497
  size:  13 bytes
  > 
  > ## Add one more commit
  > f <- file(file.path(path, "test.txt"), "wb")
  > writeChar("Hello world!\nHELLO WORLD!\nHeLlO wOrLd!\n", f, eos = NULL)
  > close(f)
  > add(repo, "test.txt")
  > blob <- lookup(repo, tree(commit(repo, "New commit message"))$id[1])
  > stopifnot(identical(content(blob),
  +                     c("Hello world!", "HELLO WORLD!", "HeLlO wOrLd!")))
  > 
  > ## Hash
  > stopifnot(identical(hash("Hello, world!\n"),
  +                     "af5626b4a114abcb82d63db7c8082c3c4756e51b"))
  > stopifnot(identical(hash("test content\n"),
  +                     "d670460b4b4aece5915caf5c68d12f560a9fe3e4"))
  > stopifnot(identical(hash(c("Hello, world!\n",
  +                            "test content\n")),
  +                     c("af5626b4a114abcb82d63db7c8082c3c4756e51b",
  +                       "d670460b4b4aece5915caf5c68d12f560a9fe3e4")))
  > stopifnot(identical(hash(c("Hello, world!\n",
  +                            NA_character_,
  +                            "test content\n")),
  +                     c("af5626b4a114abcb82d63db7c8082c3c4756e51b",
  +                       NA_character_,
  +                       "d670460b4b4aece5915caf5c68d12f560a9fe3e4")))
  > stopifnot(identical(hash(character(0)), character(0)))
  > 
  > ## Hash file
  > test_1_txt <- file(file.path(path, "test-1.txt"), "wb")
  > writeChar("Hello, world!\n", test_1_txt, eos = NULL)
  > close(test_1_txt)
  > test_2_txt <- file(file.path(path, "test-2.txt"), "wb")
  > writeChar("test content\n", test_2_txt, eos = NULL)
  > close(test_2_txt)
  > stopifnot(identical(hash("Hello, world!\n"),
  +                     hashfile(file.path(path, "test-1.txt"))))
  > stopifnot(identical(hash("test content\n"),
  +                     hashfile(file.path(path, "test-2.txt"))))
  > stopifnot(identical(hash(c("Hello, world!\n",
  +                            "test content\n")),
  +                     hashfile(c(file.path(path, "test-1.txt"),
  +                                file.path(path, "test-2.txt")))))
  > tools::assertError(hashfile(c(file.path(path, "test-1.txt"),
  +                               NA_character_,
  +                               file.path(path, "test-2.txt"))))
  Error: Failed to get error in evaluating hashfile(c(file.path(path, "te  ...
  Execution halted