示例#1
0
    def test_dummy_async_query(self):
        connection = {"host": "hostbla", "port": "8080", "path": "/"}
        entry_point = EntryPoint(connection, None)
        query = "placeholder query text"
        query_response = entry_point.create_query_connection(query)

        assert query_response['search_id'] == "uuid_1234567890"
示例#2
0
    def test_dummy_async_status(self):
        entry_point = EntryPoint(self.connection(), self.configuration())
        query_id = "uuid_1234567890"
        status_response = entry_point.create_status_connection(query_id)

        success = status_response["success"]
        assert success
        status = status_response["status"]
        assert status == Status.COMPLETED.value
示例#3
0
    def test_dummy_async_status(self):
        connection = {"host": "hostbla", "port": "8080", "path": "/"}
        entry_point = EntryPoint(connection, None)
        query_id = "uuid_1234567890"
        status_response = entry_point.create_status_connection(query_id)

        success = status_response["success"]
        assert success == True
        status = status_response["status"]
        assert status == Status.COMPLETED.value
示例#4
0
    def test_dummy_async_results(self):
        entry_point = EntryPoint(self.connection(), self.configuration())
        query_id = "uuid_1234567890"
        results_response = entry_point.create_results_connection(
            query_id, 1, 1)

        success = results_response["success"]
        assert success
        data = results_response["data"]
        assert data == "Results from search"
示例#5
0
    def test_dummy_async_results(self):
        connection = {"host": "hostbla", "port": "8080", "path": "/"}
        entry_point = EntryPoint(connection, None)
        query_id = "uuid_1234567890"
        results_response = entry_point.create_results_connection(
            query_id, 1, 1)

        success = results_response["success"]
        assert success == True
        data = results_response["data"]
        assert data == "Results from search"
示例#6
0
    def test_ping(self):
        connection = {"host": "hostbla", "port": "8080", "path": "/"}

        entry_point = EntryPoint(connection, None)
        ping_result = entry_point.ping_connection()
        assert ping_result["success"] is True
示例#7
0
 def test_is_async(self):
     connection = {"host": "hostbla", "port": "8080", "path": "/"}
     entry_point = EntryPoint(connection, None)
     check_async = entry_point.is_async()
     assert check_async
示例#8
0
 def test_ping(self):
     entry_point = EntryPoint(self.connection(), self.configuration())
     ping_result = entry_point.ping_connection()
     assert ping_result["success"] is True
示例#9
0
 def test_is_async(self):
     entry_point = EntryPoint(self.connection(), self.configuration())
     check_async = entry_point.is_async()
     assert check_async
示例#10
0
    def test_dummy_async_query(self):
        entry_point = EntryPoint(self.connection(), self.configuration())
        query = "placeholder query text"
        query_response = entry_point.create_query_connection(query)

        assert query_response['search_id'] == "uuid_1234567890"