indextest

package
v0.0.0-...-8b501b0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 6, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SuiteBase

type SuiteBase struct {
	// contains filtered or unexported fields
}

SuiteBase defines a re-usable set of index-related tests that can be executed against any type that implements index.Indexer.

func (*SuiteBase) SetIndexer

func (s *SuiteBase) SetIndexer(idx index.Indexer)

SetIndexer configures the test-suite to run all tests against idx.

func (*SuiteBase) TestFindByID

func (s *SuiteBase) TestFindByID(c *gc.C)

TestFindByID verifies the document lookup logic.

func (*SuiteBase) TestIndexDocument

func (s *SuiteBase) TestIndexDocument(c *gc.C)

TestIndexDocument verifies the indexing logic for new and existing documents.

func (*SuiteBase) TestIndexDoesNotOverridePageRank

func (s *SuiteBase) TestIndexDoesNotOverridePageRank(c *gc.C)

TestIndexDoesNotOverridePageRank verifies the indexing logic for new and existing documents.

func (*SuiteBase) TestMatchSearch

func (s *SuiteBase) TestMatchSearch(c *gc.C)

TestMatchSearch verifies the document search logic when searching for keyword matches.

func (*SuiteBase) TestMatchSearchWithOffset

func (s *SuiteBase) TestMatchSearchWithOffset(c *gc.C)

TestMatchSearchWithOffset verifies the document search logic when searching for keyword matches and skipping some results.

func (*SuiteBase) TestPhraseSearch

func (s *SuiteBase) TestPhraseSearch(c *gc.C)

TestPhraseSearch verifies the document search logic when searching for exact phrases.

func (*SuiteBase) TestUpdateScore

func (s *SuiteBase) TestUpdateScore(c *gc.C)

TestUpdateScore checks that PageRank score updates work as expected.

func (*SuiteBase) TestUpdateScoreForUnknownDocument

func (s *SuiteBase) TestUpdateScoreForUnknownDocument(c *gc.C)

TestUpdateScoreForUnknownDocument checks that a placeholder document will be created when setting the PageRank score for an unknown document.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL