Running 'spelling.R' [0s]
  Running 'testthat.R' [55s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
  > # This file is part of the standard setup for testthat.
  > # It is recommended that you do not modify it.
  > #
  > # Where should you do additional test configuration?
  > # Learn more about the roles of various files in:
  > # * https://r-pkgs.org/tests.html
  > # * https://testthat.r-lib.org/reference/test_package.html#special-files
  > 
  > library(testthat)
  > library(GitStats)
  > 
  > test_check("GitStats")
  > Pulling organizations data...
  v Data pulled in 0 secs
  
  .......
  > Pulling repositories data...
  ! Getting cached repositories data.
  i If you wish to pull the data from API once more, set `cache` parameter to `FALSE`.
  v Data pulled in 0 secs
  v Data pulled in 0 secs
  > Pulling repositories structure...
  v Data pulled in 0 secs
  Saving _problems/test-04-get_files_content-GitLab-114.R
  Saving _problems/test-04-get_files_content-GitLab-183.R
  Saving _problems/test-04-get_files_content-GitLab-200.R
  Saving _problems/test-04-get_files_content-GitLab-200.R
  Saving _problems/test-04-get_files_content-GitLab-200.R
  Saving _problems/test-04-get_files_content-GitLab-200.R
  > Pulling files content...
  v Data pulled in 0 secs
  > Pulling issues...
  v Data pulled in 0 secs
  > Pulling release logs..
  v Data pulled in 0 secs
  > Pulling repositories URLs...
  > Pulling repositories URLs...
  v Data pulled in 0 secs
  > Pulling users data...
  v Data pulled in 0 secs
  [ FAIL 6 | WARN 0 | SKIP 132 | PASS 936 ]
  
  ══ Skipped tests (132) ═════════════════════════════════════════════════════════
  • On CRAN (113): 'test-00-api-requests.R:2:3', 'test-00-api-requests.R:32:3',
    'test-00-get_orgs-GitHub.R:1:1', 'test-00-get_orgs-GitHub.R:11:1',
    'test-00-get_orgs-GitHub.R:65:1', 'test-00-get_orgs-GitHub.R:107:1',
    'test-00-get_orgs-GitLab.R:1:1', 'test-00-get_orgs-GitLab.R:9:1',
    'test-00-get_orgs-GitLab.R:34:1', 'test-00-get_orgs-GitLab.R:74:1',
    'test-00-get_orgs-GitLab.R:107:1', 'test-00-get_orgs-GitLab.R:150:1',
    'test-00-get_orgs-GitLab.R:204:1', 'test-00-get_orgs-GitLab.R:336:1',
    'test-00-get_orgs-GitLab.R:425:1', 'test-00-get_orgs-GitLab.R:455:1',
    'test-00-get_orgs-GitStats.R:41:1', 'test-00-get_orgs-GitStats.R:62:1',
    'test-01-get_repos-GitHub.R:1:1', 'test-01-get_repos-GitHub.R:10:1',
    'test-01-get_repos-GitHub.R:19:1', 'test-01-get_repos-GitHub.R:287:1',
    'test-01-get_repos-GitHub.R:323:1', 'test-01-get_repos-GitHub.R:348:1',
    'test-01-get_repos-GitHub.R:371:1', 'test-01-get_repos-GitHub.R:482:1',
    'test-01-get_repos-GitHub.R:617:1', 'test-01-get_repos-GitHub.R:729:1',
    'test-01-get_repos-GitLab.R:1:1', 'test-01-get_repos-GitLab.R:10:1',
    'test-01-get_repos-GitLab.R:163:1', 'test-01-get_repos-GitLab.R:291:1',
    'test-01-get_repos-GitLab.R:307:1', 'test-01-get_repos-GitLab.R:331:1',
    'test-01-get_repos-GitLab.R:387:1', 'test-01-get_repos-GitLab.R:452:1',
    'test-01-get_repos-GitLab.R:472:1', 'test-01-get_repos-GitLab.R:597:1',
    'test-01-get_repos-GitLab.R:660:1', 'test-01-get_repos-GitStats.R:139:1',
    'test-01-get_repos-GitStats.R:170:1', 'test-02-get_commits-GitHub.R:1:1',
    'test-02-get_commits-GitLab.R:138:1', 'test-02-get_commits-GitLab.R:165:1',
    'test-02-get_commits-GitStats.R:59:1', 'test-02-get_commits-GitStats.R:72:1',
    'test-02-get_commits-GitStats.R:108:1',
    'test-02-get_commits-GitStats.R:122:1',
    'test-03-get_files_structure-GitHub.R:1:1',
    'test-03-get_files_structure-GitHub.R:194:1',
    'test-03-get_files_structure-GitHub.R:249:1',
    'test-03-get_files_structure-GitHub.R:292:1',
    'test-03-get_files_structure-GitLab.R:1:1',
    'test-03-get_files_structure-GitLab.R:242:1',
    'test-03-get_repos_trees-GitStats.R:36:1',
    'test-03-get_repos_trees-GitStats.R:48:1',
    'test-04-get_files_content-GitHub.R:1:1',
    'test-04-get_files_content-GitHub.R:196:1',
    'test-04-get_files_content-GitHub.R:220:1',
    'test-04-get_files_content-GitLab.R:1:1',
    'test-04-get_files_content-GitLab.R:122:1',
    'test-04-get_files_content-GitLab.R:150:1',
    'test-04-get_files_content-GitLab.R:244:1',
    'test-04-get_files_content-GitLab.R:266:1',
    'test-04-get_files_content-GitLab.R:284:1', 'test-05-get_files.R:75:1',
    'test-05-get_files.R:118:1', 'test-05-get_files.R:128:1',
    'test-06-get_issues-GitHub.R:1:1', 'test-06-get_issues-GitLab.R:1:1',
    'test-06-get_issues-GitStats.R:57:1', 'test-06-get_issues-GitStats.R:69:1',
    'test-06-get_issues-GitStats.R:106:1', 'test-get_commits_stats.R:28:1',
    'test-get_issues_stats.R:27:1', 'test-get_release-GitHub.R:1:1',
    'test-get_release-GitLab.R:1:1', 'test-get_release-GitLab.R:53:1',
    'test-get_release-GitLab.R:73:1', 'test-get_release-GitStats.R:32:1',
    'test-get_release-GitStats.R:43:1', 'test-get_release-GitStats.R:75:1',
    'test-get_urls_repos-GitHub.R:54:1', 'test-get_urls_repos-GitHub.R:75:1',
    'test-get_urls_repos-GitHub.R:104:1', 'test-get_urls_repos-GitStats.R:124:1',
    'test-get_user-GitHub.R:1:1', 'test-get_user-GitLab.R:1:1',
    'test-get_users-GitStats.R:46:1', 'test-helpers.R:1:1',
    'test-helpers.R:10:1', 'test-helpers.R:47:1', 'test-helpers.R:54:1',
    'test-helpers.R:62:3', 'test-helpers.R:80:3', 'test-helpers.R:100:3',
    'test-helpers.R:117:3', 'test-helpers.R:143:3', 'test-helpers.R:173:3',
    'test-helpers.R:183:3', 'test-helpers.R:193:3', 'test-helpers.R:207:3',
    'test-set_host.R:22:3', 'test-set_host.R:81:3', 'test-set_host.R:181:3',
    'test-z-GitStats.R:7:1', 'test-z-GitStats.R:11:1', 'test-z-GitStats.R:17:3',
    'test-z-GitStats.R:34:1', 'test-z-GitStats.R:40:1', 'test-z-GitStats.R:89:1',
    'test-z-GitStats.R:119:3', 'test-z-GitStats.R:134:3'
  • Sys.getenv("GITHUB_PAT") == "" is TRUE (4): 'test-00-api-requests.R:47:3',
    'test-00-api-requests.R:70:3', 'test-00-api-requests.R:83:3',
    'test-00-api-requests.R:100:3'
  • empty test (10): 'test-00-api-requests.R:59:1',
    'test-06-get_issues-GitHub.R:49:1', 'test-set_host.R:3:1',
    'test-set_host.R:33:1', 'test-set_host.R:46:1', 'test-set_host.R:63:1',
    'test-set_host.R:92:1', 'test-set_host.R:114:1', 'test-set_host.R:132:1',
    'test-set_host.R:166:1'
  • integration_tests_skipped is TRUE (5): 'test-00-get_orgs-GitLab.R:242:3',
    'test-00-get_orgs-GitLab.R:261:3', 'test-00-get_orgs-GitLab.R:288:3',
    'test-05-get_files.R:91:3', 'test-get_release-GitHub.R:99:3'
  
  ══ Failed tests ════════════════════════════════════════════════════════════════
  ── Error ('test-04-get_files_content-GitLab.R:107:3'): Gitlab GraphQL switches to pulling files per repositories when query is too complex ──
  <httr2_failure/httr2_error/rlang_error/error/condition>
  Error in `httr2::req_perform(httr2::req_error(httr2::req_body_json(httr2::req_headers(httr2::request(paste0(self$gql_api_url, "?")), Authorization = paste0("Bearer ", token)), list(query = gql_query, variables = vars)), is_error = function(resp) FALSE))`: Failed to perform HTTP request.
  Caused by error in `curl::curl_fetch_memory()`:
  ! Stream error in the HTTP/2 framing layer [gitlab.com]:
  HTTP/2 stream 37 was not closed cleanly: INTERNAL_ERROR (err 2)
  Backtrace:
      ▆
   1. └─test_graphql_gitlab$get_files_from_org(...) at test-04-get_files_content-GitLab.R:107:3
   2.   └─self$gql_response(...)
   3.     └─private$perform_request(gql_query = gql_query, vars = vars, verbose = verbose)
   4.       └─httr2::req_perform(...)
   5.         └─httr2:::handle_resp(req, resp, error_call = error_call)
   6.           └─rlang::cnd_signal(resp)
  ── Failure ('test-04-get_files_content-GitLab.R:179:3'): checker properly identifies gitlab files responses ──
  Expected `test_graphql_gitlab_priv$response_prepared_by_iteration(files_response = test_mocker$use("gitlab_files_response_by_repos"))` to be TRUE.
  Differences:
  `actual`:   FALSE
  `expected`: TRUE 
  
  ── Failure ('test-04-get_files_content-GitLab.R:200:3'): GitLab prepares table from files response prepared in alternative way ──
  Expected `files_object` to be an S3 object.
  Actual OO type: none.
  Backtrace:
      ▆
   1. └─GitStats:::expect_files_table(gl_files_table) at test-04-get_files_content-GitLab.R:200:3
   2.   └─testthat::expect_s3_class(files_object, "data.frame") at ./helper-expect-tables.R:88:3
  ── Failure ('test-04-get_files_content-GitLab.R:200:3'): GitLab prepares table from files response prepared in alternative way ──
  Expected `files_object` to have names `c(...)`.
  Differences:
  `actual` is NULL
  `expected` is a character vector ('repo_id', 'repo_name', 'organization', 'file_path', 'file_content', ...)
  
  Backtrace:
      ▆
   1. └─GitStats:::expect_files_table(gl_files_table) at test-04-get_files_content-GitLab.R:200:3
   2.   └─testthat::expect_named(...) at ./helper-expect-tables.R:89:3
  ── Failure ('test-04-get_files_content-GitLab.R:200:3'): GitLab prepares table from files response prepared in alternative way ──
  Expected `files_object$file_size` to have type "integer".
  Actual type: "NULL"
  Backtrace:
      ▆
   1. └─GitStats:::expect_files_table(gl_files_table) at test-04-get_files_content-GitLab.R:200:3
   2.   └─testthat::expect_type(files_object$file_size, "integer") at ./helper-expect-tables.R:95:3
  ── Error ('test-04-get_files_content-GitLab.R:200:3'): GitLab prepares table from files response prepared in alternative way ──
  Error in `expect_gt(nrow(files_object), 0)`: Result of comparison must be `TRUE`, `FALSE`, or `NA`
  Backtrace:
      ▆
   1. └─GitStats:::expect_files_table(gl_files_table) at test-04-get_files_content-GitLab.R:200:3
   2.   └─testthat::expect_gt(nrow(files_object), 0) at ./helper-expect-tables.R:96:3
   3.     └─testthat:::expect_compare_(">", act, exp)
   4.       └─cli::cli_abort(...)
   5.         └─rlang::abort(...)
  
  [ FAIL 6 | WARN 0 | SKIP 132 | PASS 936 ]
  Error:
  ! Test failures.
  Execution halted