Skip to content

Commit bc3063a

Browse files
test: add unit tests for LomiClient initialization and sandbox environment
1 parent a637ab3 commit bc3063a

1 file changed

Lines changed: 15 additions & 0 deletions

File tree

tests/test_client.py

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import unittest
2+
from lomi import LomiClient
3+
4+
class TestLomiClient(unittest.TestCase):
5+
def test_init(self):
6+
client = LomiClient(api_key="test_key")
7+
self.assertEqual(client.api_key, "test_key")
8+
self.assertEqual(client.base_url, "https://api.lomi.africa")
9+
10+
def test_sandbox(self):
11+
client = LomiClient(api_key="test_key", environment="test")
12+
self.assertEqual(client.base_url, "https://sandbox.api.lomi.africa")
13+
14+
if __name__ == '__main__':
15+
unittest.main()

0 commit comments

Comments
 (0)