diff options
Diffstat (limited to 'llvm/bindings/python/tests')
-rw-r--r-- | llvm/bindings/python/tests/test_core.py | 11 | ||||
-rw-r--r-- | llvm/bindings/python/tests/test_object.py | 9 |
2 files changed, 20 insertions, 0 deletions
diff --git a/llvm/bindings/python/tests/test_core.py b/llvm/bindings/python/tests/test_core.py new file mode 100644 index 00000000000..8c4e9337053 --- /dev/null +++ b/llvm/bindings/python/tests/test_core.py @@ -0,0 +1,11 @@ +from llvm.common import find_library +from llvm.core import MemoryBuffer + +import unittest + +class TestCore(unittest.TestCase): + def test_memory_buffer_create_from_file(self): + source = find_library() + self.assertIsNotNone(source) + + mb = MemoryBuffer(filename=source) diff --git a/llvm/bindings/python/tests/test_object.py b/llvm/bindings/python/tests/test_object.py new file mode 100644 index 00000000000..afb02019672 --- /dev/null +++ b/llvm/bindings/python/tests/test_object.py @@ -0,0 +1,9 @@ +from llvm.common import find_library +from llvm.object import ObjectFile + +import unittest + +class TestObjectFile(unittest.TestCase): + def test_create_from_file(self): + source = find_library() + of = ObjectFile(filename=source) |