marking1/drumb_test2.scala
author Christian Urban <urbanc@in.tum.de>
Tue, 29 Oct 2019 09:54:52 +0000
changeset 278 0c2481cd8b1c
parent 268 e43f7e92ba26
child 281 87b9e3e2c1a7
permissions -rw-r--r--
updated

def myassert(cond : => Boolean) = {
  try {
    assert(cond)
  } catch { 
    case _ : Throwable => System.exit(1)
  }
}

myassert(get_first_price("GOOG", 1980) == None)

myassert(get_first_price("GOOG", 2010) == Some(312.204773))