2014-05-01 16:31:45 -04:00
|
|
|
;; Tests where the emited code relies on Python 3.
|
|
|
|
;; Conditionally included in nosetests runs.
|
|
|
|
|
2014-06-09 16:33:32 -04:00
|
|
|
(import [hy._compat [PY33]])
|
|
|
|
(import [hy.errors [HyCompileError]])
|
|
|
|
|
|
|
|
|
2014-05-01 16:31:45 -04:00
|
|
|
|
|
|
|
(defn test-exception-cause []
|
|
|
|
(try (raise ValueError :from NameError)
|
|
|
|
(except [e [ValueError]]
|
|
|
|
(assert (= (type (. e __cause__)) NameError)))))
|