tests/testthat/acceptance_tests/test-getAttachedAttributeFile.R

#' @author Adam Wheeler adam.wheeler@thermofisher.com
#' @author Natasha Mora natasha.mora@thermofisher.com
#' @author Scott Russell scott.russell@thermofisher.com
#' @description Tests for getAttachedAttributeFile

context("Tests for getAttachedAttributeFile()")

test_that(paste("test getAttachedAttributeFile() OData call on semantic version:", con$coreApi$semVer), {
  barcode <- getEntityByName(con$coreApi, data$testPocoType, data$testPocoName, FALSE, useVerbose = FALSE)$entity[[1]]$Barcode

  t <- getAttachedAttributeFile(con$coreApi, data$testPocoType, barcode, data$testPocoFileAttrName, useVerbose = TRUE)

  expect_equal(t$response$status_code, 200)
  expect_gt(length(t$entity), 0)
})
AmundsenJunior/pfsrsdk documentation built on July 18, 2019, 8:10 p.m.