[ADD]Test macros, end

This commit is contained in:
Fabien BOURGEOIS 2021-02-19 08:05:50 +01:00
parent ce816fc284
commit 9ac4e9f24e
2 changed files with 8 additions and 1 deletions

View File

@ -18,10 +18,17 @@
" Hy Odoo Tests Helpers and Macros "
(defmacro o-assert-equal [left right] `(.assertEqual self ~left ~right))
(defmacro o-assert-not-equal [left right] `(.assertNotEqual self ~left ~right))
(defmacro o-assert-true [val] `(.assertTrue self ~val))
(defmacro o-assert-false [val] `(.assertFalse self ~val))
(defmacro o-assert-is [left right] `(.assertIs self ~left ~right))
(defmacro o-assert-is-not [left right] `(.assertIsNot self ~left ~right))
(defmacro o-assert-is-none [val] `(.assertIsNone self ~val))
(defmacro o-assert-is-not-none [val] `(.assertIsNotNone self ~val))
(defmacro o-assert-in [left right] `(.assertIn self ~left ~right))
(defmacro o-assert-not-in [left right] `(.assertNotIn self ~left ~right))
(defmacro o-assert-is-instance [left right] `(.assertIsInstance self ~left ~right))
(defmacro o-assert-not-is-instance [left right] `(.assertNotIsInstance self ~left ~right))
(defmacro o-assert-raises [Error] `(.assertRaises self ~Error))
(defmacro odo-assert-raises [Error body]

View File

@ -2,7 +2,7 @@ from setuptools import setup, find_packages
setup(
name="hy_odoo",
version="0.6.0-pre",
version="0.6.0",
packages=find_packages(),
package_data={
'hy_odoo': ['*.hy'],