Uploaded image for project: 'SimplyE 2.0'
  1. SimplyE 2.0
  2. SIMPLY-1712 Add self-test for the Elasticsearch integration
  3. SIMPLY-1714

Make ExternalSearchIndex implement HasSelfTests and add one test

XMLWordPrintable

    • Icon: Sub-task Sub-task
    • Resolution: Done
    • Icon: Medium Medium
    • 2.3.2cm
    • Server - Core
    • None
    • S4 SIMPLY Feb 6 - Feb 19, S5 SIMPLY Feb 20 - March 5

      HasSelfTests is found in core/selftest.py. You'll need to have ExternalSearchIndex subclass this class and implement the _run_self_tests method.

      This method needs to yield a sequence of SelfTestResult objects – one for each distinct test we run. As we fill out this story, the number of tests we run will increase.

      See the _run_self_tests implementation in api/overdrive.py for an example.

      To start with, use the default search string to do a search against the search index, using ExternalSearchIndex.query_works. This will return a list of Work objects. The list of titles of the works will make a good value for the .result field of the SelfTestResult object.

            adrianaalter Adriana Alter [X] (Inactive)
            leonardrichardson Leonard Richardson [X] (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: