Running 'test_subtype.R' [71s]
Running the tests in 'tests/test_subtype.R' failed.
Complete output:
  > library(testthat)
  > library(OncoSubtype)
  Loading required package: SummarizedExperiment
  Loading required package: MatrixGenerics
  Loading required package: matrixStats
  
  Attaching package: 'MatrixGenerics'
  
  The following objects are masked from 'package:matrixStats':
  
      colAlls, colAnyNAs, colAnys, colAvgsPerRowSet, colCollapse,
      colCounts, colCummaxs, colCummins, colCumprods, colCumsums,
      colDiffs, colIQRDiffs, colIQRs, colLogSumExps, colMadDiffs,
      colMads, colMaxs, colMeans2, colMedians, colMins, colOrderStats,
      colProds, colQuantiles, colRanges, colRanks, colSdDiffs, colSds,
      colSums2, colTabulates, colVarDiffs, colVars, colWeightedMads,
      colWeightedMeans, colWeightedMedians, colWeightedSds,
      colWeightedVars, rowAlls, rowAnyNAs, rowAnys, rowAvgsPerColSet,
      rowCollapse, rowCounts, rowCummaxs, rowCummins, rowCumprods,
      rowCumsums, rowDiffs, rowIQRDiffs, rowIQRs, rowLogSumExps,
      rowMadDiffs, rowMads, rowMaxs, rowMeans2, rowMedians, rowMins,
      rowOrderStats, rowProds, rowQuantiles, rowRanges, rowRanks,
      rowSdDiffs, rowSds, rowSums2, rowTabulates, rowVarDiffs, rowVars,
      rowWeightedMads, rowWeightedMeans, rowWeightedMedians,
      rowWeightedSds, rowWeightedVars
  
  Loading required package: GenomicRanges
  Loading required package: stats4
  Loading required package: BiocGenerics
  Loading required package: generics
  
  Attaching package: 'generics'
  
  The following objects are masked from 'package:base':
  
      as.difftime, as.factor, as.ordered, intersect, is.element, setdiff,
      setequal, union
  
  
  Attaching package: 'BiocGenerics'
  
  The following objects are masked from 'package:stats':
  
      IQR, mad, sd, var, xtabs
  
  The following objects are masked from 'package:base':
  
      Filter, Find, Map, Position, Reduce, anyDuplicated, aperm, append,
      as.data.frame, basename, cbind, colnames, dirname, do.call,
      duplicated, eval, evalq, get, grep, grepl, is.unsorted, lapply,
      mapply, match, mget, order, paste, pmax, pmax.int, pmin, pmin.int,
      rank, rbind, rownames, sapply, saveRDS, table, tapply, unique,
      unsplit, which.max, which.min
  
  Loading required package: S4Vectors
  
  Attaching package: 'S4Vectors'
  
  The following object is masked from 'package:utils':
  
      findMatches
  
  The following objects are masked from 'package:base':
  
      I, expand.grid, unname
  
  Loading required package: IRanges
  
  Attaching package: 'IRanges'
  
  The following object is masked from 'package:grDevices':
  
      windows
  
  Loading required package: GenomeInfoDb
  Loading required package: Biobase
  Welcome to Bioconductor
  
      Vignettes contain introductory material; view with
      'browseVignettes()'. To cite Bioconductor, see
      'citation("Biobase")', and for packages 'citation("pkgname")'.
  
  
  Attaching package: 'Biobase'
  
  The following object is masked from 'package:MatrixGenerics':
  
      rowMedians
  
  The following objects are masked from 'package:matrixStats':
  
      anyMissing, rowMedians
  
  > 
  > test_that(desc = "Whether subtype function works properly", {
  +   data <- get_median_centered(example_fpkm)
  +   data <- assays(data)$centered
  +   rownames(data) <- rowData(example_fpkm)$external_gene_name
  +   res <- ml_subtype(data)
  +   expect_equal(class(res)[1], "SubtypeClass")
  + })
  trying URL 'https://raw.githubusercontent.com/DadongZ/OncoSubtype_data/main/data/lusc_tcga.rda'
  ── Warning: Whether subtype function works properly ────────────────────────────
  URL 'https://raw.githubusercontent.com/DadongZ/OncoSubtype_data/main/data/lusc_tcga.rda': Timeout of 60 seconds was reached
  Backtrace:
      ▆
   1. └─OncoSubtype::ml_subtype(data)
   2.   └─OncoSubtype::load_dataset_from_github(disease = disease)
   3.     └─utils::download.file(url, destfile = local_dataset_path, mode = "wb")
  
  ── Error: Whether subtype function works properly ──────────────────────────────
  Error in `download.file(url, destfile = local_dataset_path, mode = "wb")`: cannot open URL 'https://raw.githubusercontent.com/DadongZ/OncoSubtype_data/main/data/lusc_tcga.rda'
  Backtrace:
      ▆
   1. └─OncoSubtype::ml_subtype(data)
   2.   └─OncoSubtype::load_dataset_from_github(disease = disease)
   3.     └─utils::download.file(url, destfile = local_dataset_path, mode = "wb")
  
  Error:
  ! Test failed
  Backtrace:
      ▆
   1. ├─testthat::test_that(...)
   2. │ └─withr (local) `<fn>`()
   3. └─reporter$stop_if_needed()
   4.   └─rlang::abort("Test failed", call = NULL)
  Execution halted