[Xapian-devel] when file for test is added into database

Hurricane Tong zhangshangtong.cpp at qq.com
Sat Jun 7 17:54:52 BST 2014


For example, in api_anydb.cc, line 1955,

DEFINE_TESTCASE(getdoc1, backend) {
    Xapian::Database db(get_database("apitest_onedoc"));
    Xapian::Document doc(db.get_document(1));

get_database seems only to open the database or create it, but not add a doc to it.
So I get an exception in db.get_document(1), 

DocNotFoundError: Document 1 not found.

When is concerning docs added?
Shangtong Zhang,Second Year Undergraduate,
School of Computer Science,
Fudan University, China.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xapian.org/pipermail/xapian-devel/attachments/20140608/72544cc9/attachment.html>

More information about the Xapian-devel mailing list