tests/testthat/unify_parameters.R

context("unify parameters")


test_that("", {
  p1 = ParameterType(x = IntegerType())
  p2 = ParameterType(x = IntegerType())

  result = unify(p1, p2)
})


test_that("", {
  p1 = ParameterType(IntegerType())
  p2 = ParameterType(x = TypeVariable("a"))

  result = unify(p1, p2)
})


test_that("", {
  p1 = ParameterType(IntegerType(), x = TypeVariable("a"))
  p2 = ParameterType(x = NumericType())

  unify(p1, p2)
})
nick-ulle/typesys documentation built on Jan. 21, 2020, 5:13 p.m.