xapian-core  1.4.26
Functions
api_posdb.cc File Reference

tests which need a backend with positional information More...

#include <config.h>
#include "api_posdb.h"
#include <string>
#include <vector>
#include <xapian.h>
#include "testsuite.h"
#include "testutils.h"
#include "apitest.h"
+ Include dependency graph for api_posdb.cc:

Go to the source code of this file.

Functions

 DEFINE_TESTCASE (near1, positional)
 Simple test of NEAR. More...
 
 DEFINE_TESTCASE (near2, positional)
 Test NEAR over operators. More...
 
 DEFINE_TESTCASE (phrase1, positional)
 Simple test of PHRASE. More...
 
 DEFINE_TESTCASE (phrase2, positional)
 Test PHRASE over operators. More...
 
 DEFINE_TESTCASE (poslist1, positional)
 Test getting position lists from databases. More...
 
 DEFINE_TESTCASE (poslist2, positional &&writable)
 
 DEFINE_TESTCASE (poslist3, positional &&writable)
 Test playing with a positionlist, testing skip_to in particular. More...
 
 DEFINE_TESTCASE (positfromtermit1, positional)
 

Detailed Description

tests which need a backend with positional information

Definition in file api_posdb.cc.

Function Documentation

◆ DEFINE_TESTCASE() [1/8]

DEFINE_TESTCASE ( near1  ,
positional   
)

◆ DEFINE_TESTCASE() [2/8]

DEFINE_TESTCASE ( near2  ,
positional   
)

◆ DEFINE_TESTCASE() [3/8]

DEFINE_TESTCASE ( phrase1  ,
positional   
)

◆ DEFINE_TESTCASE() [4/8]

DEFINE_TESTCASE ( phrase2  ,
positional   
)

◆ DEFINE_TESTCASE() [5/8]

DEFINE_TESTCASE ( poslist1  ,
positional   
)

Test getting position lists from databases.

Definition at line 466 of file api_posdb.cc.

References get_database(), Xapian::Database::positionlist_begin(), Xapian::Database::positionlist_end(), stemmer, TEST, and TEST_EQUAL.

◆ DEFINE_TESTCASE() [6/8]

DEFINE_TESTCASE ( poslist2  ,
positional &&  writable 
)

◆ DEFINE_TESTCASE() [7/8]

DEFINE_TESTCASE ( poslist3  ,
positional &&  writable 
)

Test playing with a positionlist, testing skip_to in particular.

(used to be quartztest's test_positionlist1).

Definition at line 551 of file api_posdb.cc.

References Xapian::WritableDatabase::add_document(), Xapian::Document::add_posting(), get_writable_database(), Xapian::Database::positionlist_begin(), Xapian::Database::positionlist_end(), Xapian::PositionIterator::skip_to(), TEST, and TEST_EQUAL.

◆ DEFINE_TESTCASE() [8/8]

DEFINE_TESTCASE ( positfromtermit1  ,
positional   
)