def test_add_documents_no_device(self):
        """No device should be in path if no device is set
        """
        temp_client = copy.deepcopy(self.client)

        mock__post = mock.MagicMock()

        @mock.patch("marqo._httprequests.HttpRequests.post", mock__post)
        def run():
            temp_client.index(self.image_index_name).add_documents(documents=[
                {"d1": "blah"}, {"d2", "some data"}
            ], tensor_fields=[])
            return True

        assert run()

        args, kwargs = mock__post.call_args
        assert "device" not in kwargs["path"]
No device should be in path if no device is set
        
tests/api_tests/v1/tests/api_tests/unstructured_index/test_add_documents.py