| Server IP : 172.67.134.116 / Your IP : 216.73.217.22 Web Server : Apache System : Linux server.rehabsharif.com 5.14.0-611.54.3.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Thu May 7 16:31:24 EDT 2026 x86_64 User : nobi37te ( 1003) PHP Version : 8.2.33 Disable Function : exec,passthru,shell_exec,system MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /usr/lib/python3.9/site-packages/tracer/tests/ |
Upload File : |
from .__meta__ import * from tracer.query import Query, Lazy class TestQuery(unittest.TestCase): def setUp(self): self.query = Query(tracer=TracerMock) def test_affected_applications(self): apps_query = self.query.affected_applications() self.assertIsInstance(apps_query, Lazy) self.assertTrue(hasattr(apps_query, "get")) self.assertListEqual(list(apps_query.get()), ["A", "B", "C"]) class TracerMock(object): def __init__(self, *args): pass def trace_affected(self, user=None): return ["A", "B", "C"] if __name__ == '__main__': unittest.main()