Fix compilation error in new document_api_tests.cpp test merged from d176839bf4652317f6fd01ec7dfe1cd1017b8e5f (close #515)